[Bug c++/102963] New: [modules] ICE failed static_assert of concept
johelegp at gmail dot com
gcc-bugzilla@gcc.gnu.org
Wed Oct 27 16:05:05 GMT 2021
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102963
Bug ID: 102963
Summary: [modules] ICE failed static_assert of concept
Product: gcc
Version: 12.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: johelegp at gmail dot com
CC: johelegp at gmail dot com
Target Milestone: ---
See https://godbolt.org/z/7h1MPqe1h.
mod.cpp:
```C++
export module mod;
export template<class T>
concept C = false;
```
test.cpp:
```C++
import mod;
static_assert(C<int>);
```
Output:
```
test.cpp:2:15: error: static assertion failed
2 | static_assert(C<int>);
| ^~~~~~
test.cpp:2:15: note: constraints not satisfied
'
In module mod, imported at /app/test.cpp:1:
mod.cpp:3:9: in import_entity_index, at cp/module.cc:3953
3 | concept C = false;
| ^~~~~
0x20037b9 internal_error(char const*, ...)
???:0
0x7d6c17 fancy_abort(char const*, int, char const*)
???:0
0x966d5c get_importing_module(tree_node*, bool)
???:0
0x201fcb1 pp_format(pretty_printer*, text_info*)
???:0
0x2020330 pp_format_verbatim(pretty_printer*, text_info*)
???:0
0x2020411 pp_verbatim(pretty_printer*, char const*, ...)
???:0
0x9046d7 maybe_print_single_constraint_context(diagnostic_context*, tree_node*)
???:0
0x20023f1 diagnostic_report_diagnostic(diagnostic_context*, diagnostic_info*)
???:0
0x2002d4d inform(unsigned int, char const*, ...)
???:0
0x86008f diagnose_constraints(unsigned int, tree_node*, tree_node*)
???:0
0xab8483 finish_static_assert(tree_node*, tree_node*, unsigned int, bool, bool)
???:0
0xa0bea5 c_parse_file()
???:0
0xb92e22 c_common_parse_file()
???:0
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.
```
More information about the Gcc-bugs
mailing list