MCPcopy Create free account
hub / github.com/compiler-explorer/compiler-explorer / isUnit

Function isUnit

lib/compilers/pascal-utils.ts:30–33  ·  view source on GitHub ↗
(source: string)

Source from the content-addressed store, hash-verified

28}
29
30export function isUnit(source: string) {
31 const re = /\s?unit\s+([\w.-]*);/i;
32 return !!re.test(source);
33}
34
35export function getUnitname(source: string) {
36 const re = /\s?unit\s+([\w.-]*);/i;

Callers

nothing calls this directly

Calls 1

testMethod · 0.80

Tested by

no test coverage detected