[pushed] c++: add fixed test [PR118391]
Checks
Context |
Check |
Description |
linaro-tcwg-bot/tcwg_gcc_build--master-arm |
success
|
Build passed
|
linaro-tcwg-bot/tcwg_gcc_build--master-aarch64 |
success
|
Build passed
|
linaro-tcwg-bot/tcwg_gcc_check--master-aarch64 |
success
|
Test passed
|
linaro-tcwg-bot/tcwg_gcc_check--master-arm |
success
|
Test passed
|
Commit Message
Tested x86_64-pc-linux-gnu, applying to trunk.
-- >8 --
Fixed by r15-6740.
PR c++/118391
gcc/testsuite/ChangeLog:
* g++.dg/cpp2a/lambda-uneval20.C: New test.
---
gcc/testsuite/g++.dg/cpp2a/lambda-uneval20.C | 15 +++++++++++++++
1 file changed, 15 insertions(+)
create mode 100644 gcc/testsuite/g++.dg/cpp2a/lambda-uneval20.C
base-commit: 81bcf412c1c221bc2557666a6ca8381dac1de097
new file mode 100644
@@ -0,0 +1,15 @@
+// PR c++/118391
+// { dg-do compile { target c++20 } }
+
+template<typename>
+using A = int;
+
+template<typename T>
+using B = decltype([]<typename> {}.template operator()<T>());
+
+template<typename T>
+using C = A<B<T>>;
+
+C<int> x;
+
+int main() {}