2 // { dg-do compile { target c++1y } }
3 // { dg-options "-g -dA -fno-debug-types-section" }
4 // We're looking for something like
6 // .uleb128 0x3 # (DIE (0x33) DW_TAG_subprogram)
7 // .ascii "a1\0" # DW_AT_name
8 // .long 0x4c # DW_AT_type
10 // .uleb128 0x5 # (DIE (0x4c) DW_TAG_unspecified_type)
11 // .long .LASF6 # DW_AT_name: "auto"
13 // .uleb128 0x7 # (DIE (0x57) DW_TAG_subprogram)
14 // .long 0x33 # DW_AT_specification
15 // .long 0x87 # DW_AT_type
17 // .uleb128 0x9 # (DIE (0x87) DW_TAG_base_type)
18 // .ascii "int\0" # DW_AT_name
20 // { dg-final { scan-assembler "a1.*(0x\[0-9a-f]+)\[^\n\r]*DW_AT_type.*\\1. DW_TAG_unspecified_type.*DW_AT_specification\[\n\r]{1,2}\[^\n\r]*(0x\[0-9a-f]+)\[^\n\r]*DW_AT_type.*\\2. DW_TAG_base_type" } }
24 auto a1 () { return 42; }