Operators won't parse ('Implementation' expected found 'operator')

Issue #114 new
coth created an issue

There is an error in Problems - Argument out of range, when using ** operator defined in Math unit. That is mathematical power operator.

Also throws error on a line in Math.pp where it is defined - 'Implementation' expected found 'operator'.

Both settings are set to correct and works

"omnipascal.defaultDevelopmentEnvironment": "FreePascal",
"omnipascal.freePascalSourcePath": "c:/fpc/3.0.4",

Comments (3)

  1. coth reporter

    This prevents files from parsing. So functions behind error will not appear in outline and navigation bar.

    {
        "resource": "/C:/fpc/3.2.0/fpcsrc/rtl/objpas/math.pp",
        "owner": "objectpascal",
        "code": "A4711",
        "severity": 8,
        "message": "'Implementation' expected found 'operator'",
        "startLineNumber": 394,
        "startColumn": 1,
        "endLineNumber": 394,
        "endColumn": 1
    }
    

  2. coth reporter

    Another example is using class operators
    error: "'Colon' expected found ';'",

    class operator Initialize(var ARecord: TRecord);
    

    This also makes most OmniPascal function non-functional in the file.

  3. Log in to comment