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

Function getProgName

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

Source from the content-addressed store, hash-verified

43}
44
45export function getProgName(source: string) {
46 const re = /\s?program\s+([\w.-]*);/i;
47 const match = source.match(re);
48 if (match) {
49 return match[1];
50 }
51
52 return 'prog';
53}

Callers

nothing calls this directly

Calls 1

matchMethod · 0.80

Tested by

no test coverage detected