From 25660ac47532e4a6e0943e20f42ee34b1165a690 Mon Sep 17 00:00:00 2001 From: Joey Yakimowich-Payne Date: Mon, 4 May 2020 08:10:46 -0600 Subject: Fix missing comment in ast2 --- nimterop/ast2.nim | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/nimterop/ast2.nim b/nimterop/ast2.nim index 759419c..fd70b46 100644 --- a/nimterop/ast2.nim +++ b/nimterop/ast2.nim @@ -1651,7 +1651,8 @@ proc addDecl(gState: State, node: TSNode) = if node[i].getAtom().getPxName(1) == "pointer_declarator": # proc var if firstDecl: - # If + # If it's the first declaration, use the whole node + # to get the comment above/below commentNodes = gState.getCommentNodes(node) firstDecl = false else: @@ -1660,7 +1661,8 @@ proc addDecl(gState: State, node: TSNode) = else: # proc if firstDecl: - # If + # If it's the first declaration, use the whole node + # to get the comment above/below commentNodes = gState.getCommentNodes(node) firstDecl = false else: -- cgit v1.2.3