-
Notifications
You must be signed in to change notification settings - Fork 10.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ast-print generates wrong output for braced-init-list constructor initializations #64061
Labels
clang:frontend
Language frontend issues, e.g. anything involving "Sema"
Comments
I already have a fix and will issues a merge request as soon as a dependent merge request is merged. It currently takes me several weeks to get a simple merge processed. Any tips are appreciated! |
EugeneZelenko
added
clang:frontend
Language frontend issues, e.g. anything involving "Sema"
and removed
new issue
labels
Jul 24, 2023
@llvm/issue-subscribers-clang-frontend |
strimo378
added a commit
that referenced
this issue
Jul 27, 2023
DeclPrinter::PrintConstructorInitializers did not consider curly constructor initializers. Any curly constructor initializers (e.g. `A() : Field{}`) was printed with round brackets (e.g. `A() : Field({})`). #64061 Reviewed By: aaron.ballman Differential Revision: https://reviews.llvm.org/D156307
eymay
pushed a commit
to eymay/llvm-project
that referenced
this issue
Jul 28, 2023
DeclPrinter::PrintConstructorInitializers did not consider curly constructor initializers. Any curly constructor initializers (e.g. `A() : Field{}`) was printed with round brackets (e.g. `A() : Field({})`). llvm#64061 Reviewed By: aaron.ballman Differential Revision: https://reviews.llvm.org/D156307
fixed |
razmser
pushed a commit
to razmser/llvm-project
that referenced
this issue
Sep 8, 2023
DeclPrinter::PrintConstructorInitializers did not consider curly constructor initializers. Any curly constructor initializers (e.g. `A() : Field{}`) was printed with round brackets (e.g. `A() : Field({})`). llvm#64061 Reviewed By: aaron.ballman Differential Revision: https://reviews.llvm.org/D156307
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi all,
the AST printer (-Xclang -ast-print) generates wrong output for braced-init-list constructor initializations. E.g.
field{}
is always outfield({})
.The following code (see https://godbolt.org/z/6cvG8bGje)
is generates as
Especially, the output of
b({})
is incorrect C++ code.The text was updated successfully, but these errors were encountered: