compiler/vm/vmdeps

  Source   Edit

Procs

proc errorReportToString(c: ConfigRef; error: Report): string {.
    ...raises: [ValueError, KeyError, Exception, ERecoverableError],
    tags: [ReadDirEffect, RootEffect, ReadIOEffect].}
Turns the given error report into text that is meant to be passed on to the user   Source   Edit
proc opMapTypeImplToAst(cache: IdentCache; t: PType; info: TLineInfo;
                        idgen: IdGenerator): PNode {.
    ...raises: [KeyError, Exception], tags: [RootEffect].}
  Source   Edit
proc opMapTypeInstToAst(cache: IdentCache; t: PType; info: TLineInfo;
                        idgen: IdGenerator): PNode {.
    ...raises: [KeyError, Exception], tags: [RootEffect].}
  Source   Edit
proc opMapTypeToAst(cache: IdentCache; t: PType; info: TLineInfo;
                    idgen: IdGenerator): PNode {....raises: [KeyError, Exception],
    tags: [RootEffect].}
  Source   Edit
proc opSlurp(file: string; info: TLineInfo; module: PSym; conf: ConfigRef): string {.
    ...raises: [OSError, Exception, KeyError, ERecoverableError],
    tags: [ReadDirEffect, ReadIOEffect, RootEffect].}
  Source   Edit
proc parseCode(code: string; cache: IdentCache; config: ConfigRef;
               filename: string; line: int): Result[PNode, Report] {.
    ...raises: [IOError, Exception, ValueError, ERecoverableError, KeyError],
    tags: [ReadIOEffect, RootEffect, ReadDirEffect].}
Invokes the parser for the given code and returns either the parsed AST or the first error that occurred during parsing   Source   Edit
proc parseCode(code: string; cache: IdentCache; config: ConfigRef;
               info: TLineInfo): Result[PNode, Report] {.inline,
    ...raises: [IOError, Exception, ValueError, ERecoverableError, KeyError],
    tags: [ReadIOEffect, RootEffect, ReadDirEffect].}
Version of parseCode that accepts a TLineInfo   Source   Edit
proc toExceptionAst(name, msg: sink string): PNode {....raises: [], tags: [].}
Creates the AST as for an exception object as expected by the report.   Source   Edit