JS improve indent (#12581)

* JSgen make indent be all spaces, instead of mixed spaces and tabs, for generated JS
This commit is contained in:
Juan Carlos
2019-11-03 04:03:03 -03:00
committed by Andreas Rumpf
parent ceda586d88
commit 4c9a7e6f00
2 changed files with 2 additions and 2 deletions

View File

@@ -45,7 +45,7 @@
### Compiler changes
- JS target indent is all spaces, instead of mixed spaces and tabs, for generated JavaScript.
## Bugfixes

View File

@@ -110,7 +110,7 @@ proc indentLine(p: PProc, r: Rope): Rope =
var p = p
while true:
for i in 0 ..< p.blocks.len + p.extraIndent:
prepend(result, "\t".rope)
prepend(result, rope" ")
if p.up == nil or p.up.prc != p.prc.owner:
break
p = p.up