Issue 172136
Summary Return value of std::meta::bases_of is not usable in consteval context
Labels new issue
Assignees
Reporter hutorny
    This code snippet
```c++
template <typename T>
consteval auto list_bases() {
  std::string result {};
  for(auto base : bases_of(^^T, std::meta::access_context::unchecked())) {
    result += identifier_of(^^T);
    result += ": ";
    result += identifier_of(base);
    result += '\n';
  }
  return std::define_static_string(result);
}
```
fails to compile with clang, works with gcc: [example on godbolt](https://godbolt.org/z/98b4cbG87)

_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to