summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorAndreas Rumpf <rumpf_a@web.de>2016-04-17 11:56:04 +0200
committerAndreas Rumpf <rumpf_a@web.de>2016-04-17 11:56:04 +0200
commitef99a2cf1538a305319563674b03bdb850865d28 (patch)
tree678cf131eaaabcb98885af1ad844e4283e6c3a5e
parentaf70254c7b508b6658b50ec8b4fb9465a02acb3f (diff)
downloadNim-ef99a2cf1538a305319563674b03bdb850865d28.tar.gz
small bugfix for the AST renderer
-rw-r--r--compiler/renderer.nim2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/renderer.nim b/compiler/renderer.nim
index 03f6d4832..f0ee137e9 100644
--- a/compiler/renderer.nim
+++ b/compiler/renderer.nim
@@ -802,7 +802,7 @@ proc doParamsAux(g: var TSrcGen, params: PNode) =
     gsemicolon(g, params, 1)
     put(g, tkParRi, ")")
 
-  if params.sons[0].kind != nkEmpty:
+  if params.len > 0 and params.sons[0].kind != nkEmpty:
     putWithSpace(g, tkOpr, "->")
     gsub(g, params.sons[0])