mirror of
https://github.com/nim-lang/Nim.git
synced 2026-02-14 23:33:28 +00:00
bugfix: ha.echo should be accepted
This commit is contained in:
@@ -490,10 +490,12 @@ proc getCompileCFileCmd*(cfilename: string, isExternal = false): string =
|
||||
includeCmd = ""
|
||||
compilePattern = cc[c].compilerExe
|
||||
|
||||
# XXX fix the grammar finally, we need multi-line if expressions:
|
||||
var cfile = if noAbsolutePaths(): extractFileName(cfilename) else: cfilename
|
||||
var objfile = if not isExternal or noAbsolutePaths(): toObjFile(
|
||||
cfile) else: completeCFilePath(toObjFile(cfile))
|
||||
var cfile = if noAbsolutePaths(): extractFileName(cfilename)
|
||||
else: cfilename
|
||||
var objfile = if not isExternal or noAbsolutePaths():
|
||||
toObjFile(cfile)
|
||||
else:
|
||||
completeCFilePath(toObjFile(cfile))
|
||||
cfile = quoteIfContainsWhite(AddFileExt(cfile, cExt))
|
||||
objfile = quoteIfContainsWhite(objfile)
|
||||
result = quoteIfContainsWhite(compilePattern % [
|
||||
|
||||
@@ -1188,8 +1188,9 @@ proc SemStmt(c: PContext, n: PNode): PNode =
|
||||
if gCmd == cmdInteractive:
|
||||
result = buildEchoStmt(c, semExpr(c, n))
|
||||
else:
|
||||
LocalError(n.info, errStmtExpected)
|
||||
result = ast.emptyNode
|
||||
result = semExprNoType(c, n)
|
||||
#LocalError(n.info, errStmtExpected)
|
||||
#result = ast.emptyNode
|
||||
if result == nil: InternalError(n.info, "SemStmt: result = nil")
|
||||
incl(result.flags, nfSem)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user