summaryrefslogtreecommitdiff
path: root/pycparser/c_generator.py
diff options
context:
space:
mode:
Diffstat (limited to 'pycparser/c_generator.py')
-rw-r--r--pycparser/c_generator.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/pycparser/c_generator.py b/pycparser/c_generator.py
index 36b95fb..983d578 100644
--- a/pycparser/c_generator.py
+++ b/pycparser/c_generator.py
@@ -399,6 +399,8 @@ class CGenerator(object):
# compute its own indentation.
#
return self.visit(n)
+ elif typ in (c_ast.If,):
+ return indent + self.visit(n)
else:
return indent + self.visit(n) + '\n'