[all-commits] [llvm/llvm-project] 6e08ac: [flang][NFC] Add a no-arg constructor for `Verbatim`.
Jordan Rupprecht via All-commits
all-commits at lists.llvm.org
Mon Dec 5 07:30:45 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 6e08ac8dce919c7497876d36a04a05ffc52d0e93
https://github.com/llvm/llvm-project/commit/6e08ac8dce919c7497876d36a04a05ffc52d0e93
Author: Samira Bazuzi <bazuzi at google.com>
Date: 2022-12-05 (Mon, 05 Dec 2022)
Changed paths:
M flang/include/flang/Parser/parse-tree.h
Log Message:
-----------
[flang][NFC] Add a no-arg constructor for `Verbatim`.
In C++20, types that declare or delete any constructors are no longer aggregates, breaking compilation of many existing uses of aggregate initialization.
Although `Verbatim` declares itself to not have a no-arg default constructor, this is circumvented in `basic-parsers.h` which returns a `RESULT{}` a.k.a. `Verbatim{}`. Adding the no-arg constructor while still deleting the copy/assignment constructors maintains the current state and also supports eventually building this in c++20 mode.
Fix suggested in https://discourse.llvm.org/t/build-failure-when-attempting-to-build-flang-with-c-20/66953.
Reviewed By: klausler
Differential Revision: https://reviews.llvm.org/D139228
More information about the All-commits
mailing list