comparison gcc/testsuite/g++.dg/abi/mangle53.C @ 145:1830386684a0

gcc-9.2.0
author anatofuz
date Thu, 13 Feb 2020 11:34:05 +0900
parents 04ced10e8804
children
comparison
equal deleted inserted replaced
131:84e7813d76e9 145:1830386684a0
1 // { dg-do compile { target c++11 } } 1 // { dg-do compile { target c++11 } }
2 2
3 bool b; 3 bool b;
4 int i;
4 // { dg-final { scan-assembler "_Z1fIiEDTquL_Z1bEfp_twLi42EET_" } } 5 // { dg-final { scan-assembler "_Z1fIiEDTquL_Z1bEfp_twLi42EET_" } }
5 template <class T> auto f (T t) -> decltype(b?t:throw 42) { return 0; } 6 template <class T> auto f (T t) -> decltype(b?t:throw 42) { return i; }
6 // { dg-final { scan-assembler "_Z2f2IiEDTquL_Z1bEfp_trET_" } } 7 // { dg-final { scan-assembler "_Z2f2IiEDTquL_Z1bEfp_trET_" } }
7 template <class T> auto f2 (T t) -> decltype(b?t:throw) { return 0; } 8 template <class T> auto f2 (T t) -> decltype(b?t:throw) { return i; }
8 9
9 int main() 10 int main()
10 { 11 {
11 f(0); 12 f(0);
12 f2(0); 13 f2(0);