We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 298182a commit fa739c0Copy full SHA for fa739c0
1 file changed
transpyle/cpp/unparser.py
@@ -306,10 +306,16 @@ def _arg(self, t):
306
self.write(t.arg)
307
308
def _Comment(self, node):
309
- if node.eol:
310
- self.write(' //')
+ if node.value.s.startswith("pragma"):
+ if node.eol:
311
+ self.write('\n#')
312
+ else:
313
+ self.fill('#')
314
else:
- self.fill('//')
315
316
+ self.write(' //')
317
318
+ self.fill('//')
319
self.write(node.value.s)
320
321
def _NameConstant(self, node):
0 commit comments