From ef16a51223a4b73eed74c40ce9938248ab6b4b8a Mon Sep 17 00:00:00 2001 From: Xavier Leroy Date: Fri, 22 May 2015 11:13:23 +0200 Subject: In AST.calling_conventions, record whether the original C function was "old-style" unprototyped. Use this info in printing function types for Csyntax and Clight. --- cfrontend/PrintCsyntax.ml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'cfrontend/PrintCsyntax.ml') diff --git a/cfrontend/PrintCsyntax.ml b/cfrontend/PrintCsyntax.ml index bde61cc7..d890c820 100644 --- a/cfrontend/PrintCsyntax.ml +++ b/cfrontend/PrintCsyntax.ml @@ -123,7 +123,7 @@ let rec name_cdecl id ty = if not first then Buffer.add_string b ", "; Buffer.add_string b (name_cdecl "" t1); add_args false tl in - add_args true args; + if not cconv.cc_unproto then add_args true args; Buffer.add_char b ')'; name_cdecl (Buffer.contents b) res | Tstruct(name, a) -> -- cgit