You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
//=== Cpp2 type declarations ====================================================
#include"cpp2util.h"//=== Cpp2 type definitions and function declarations ===========================autoinlineconstexpr f = []() -> void{if ((std::move(x))) {static_cast<void>(0);}};
automain() -> int;
//=== Cpp2 function definitions =================================================automain() -> int{}
Title: Missing declaration in initializer of constexpr variable.
Minimal reproducer (https://cpp2.godbolt.org/z/vqsP8drv8):
Commands:
cppfront main.cpp2 clang++18 -std=c++23 -stdlib=libc++ -lc++abi -pedantic-errors -Wall -Wextra -Wconversion -Werror=unused-result -I . main.cpp
Expected result:
x
to be declared in the emitted lambda expression.Actual result and error:
Cpp2 lowered to Cpp1:
The text was updated successfully, but these errors were encountered: