CompileErrors/C0005
C0005 - Sub defined within an argument (missing closing parenthesis?)
Description
C0005 is issued when a subroutine definition is encountered but the compiler is expecting an argument to a previous command.
C0005 is often accompanied by CompileErrors/A0001 when the cause is a missing closing parenthesis, but may be encountered alone when permissive parenthesis mode is enabled.
Example of Cause
SetFlag expects a single literal argument.
ASubroutine:
SetFlag
NewSubroutine: { C0005 - Sub defined within an argument (missing closing parenthesis?) }
RETURN
Resolution
Add the missing arguments or missing parenthesis, and any necessary RETURN statements to avoid CompileErrors/C0006.
ASubroutine:
SetFlag('X')
RETURN
NewSubroutine: { No error }
RETURN