bugfix: #line generation for windows
This commit is contained in:
parent
d5dd4669df
commit
a1cdd6e7ff
3 changed files with 14 additions and 3 deletions
|
|
@ -18,8 +18,8 @@ proc genLineDir(p: BProc, t: PNode) =
|
|||
if line < 0:
|
||||
line = 0 # negative numbers are not allowed in #line
|
||||
if optLineDir in p.Options and line > 0:
|
||||
appff(p.s[cpsStmts], "#line $2 \"$1\"$n", "; line $2 \"$1\"$n",
|
||||
[toRope(toFilename(t.info)), toRope(line)])
|
||||
appff(p.s[cpsStmts], "#line $2 $1$n", "; line $2 \"$1\"$n",
|
||||
[makeCString(toFilename(t.info)), toRope(line)])
|
||||
if ({optStackTrace, optEndb} * p.Options == {optStackTrace, optEndb}) and
|
||||
(p.prc == nil or sfPure notin p.prc.flags):
|
||||
appcg(p, cpsStmts, "#endb($1);$n", [toRope(line)])
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue