|
| 1 | + template <typename T> |
| 2 | +//^^^^^^^^ definition [..] `<file>/templates.cc`/ |
| 3 | +// ^ definition local 0 |
| 4 | + T zero = 0; |
| 5 | +//^ reference local 0 |
| 6 | +// ^^^^ definition [..] zero. |
| 7 | +// ^^^^ definition [..] zero. |
| 8 | + |
| 9 | + template <typename T> |
| 10 | +// ^ definition local 1 |
| 11 | + struct C { |
| 12 | +// ^ definition [..] C# |
| 13 | + int mono = 0; |
| 14 | +// ^^^^ definition [..] C#mono. |
| 15 | + |
| 16 | + T from_param = 0; |
| 17 | +// ^ reference local 1 |
| 18 | +// ^^^^^^^^^^ definition [..] C#from_param. |
| 19 | + |
| 20 | + static int static_mono; |
| 21 | +// ^^^^^^^^^^^ definition [..] C#static_mono. |
| 22 | + static const int static_const_mono = 0; |
| 23 | +// ^^^^^^^^^^^^^^^^^ definition [..] C#static_const_mono. |
| 24 | + |
| 25 | + static T static_from_param; |
| 26 | +// ^ reference local 1 |
| 27 | +// ^^^^^^^^^^^^^^^^^ definition [..] C#static_from_param. |
| 28 | + static const T static_const_from_param = T(); |
| 29 | +// ^ reference local 1 |
| 30 | +// ^^^^^^^^^^^^^^^^^^^^^^^ definition [..] C#static_const_from_param. |
| 31 | +// ^ reference local 1 |
| 32 | + |
| 33 | + template <typename U> |
| 34 | +// ^ definition local 2 |
| 35 | + static const U static_templated = 0; |
| 36 | +// ^ reference local 2 |
| 37 | +// ^^^^^^^^^^^^^^^^ definition [..] C#static_templated. |
| 38 | + }; |
| 39 | + |
| 40 | + template <typename T> |
| 41 | +// ^ definition local 3 |
| 42 | + int C<T>::static_mono = 0; |
| 43 | +// ^ reference [..] C# |
| 44 | +// ^ reference [..] C# |
| 45 | +// ^^^^^^^^^^^ definition [..] C#static_mono. |
| 46 | +// ^^^^^^^^^^^ definition [..] C#static_mono. |
| 47 | + |
| 48 | + template <typename T> |
| 49 | +// ^ definition local 4 |
| 50 | + T C<T>::static_from_param = 0; |
| 51 | +//^ reference local 4 |
| 52 | +// ^ reference [..] C# |
| 53 | +// ^ reference [..] C# |
| 54 | +// ^^^^^^^^^^^^^^^^^ definition [..] C#static_from_param. |
| 55 | +// ^^^^^^^^^^^^^^^^^ definition [..] C#static_from_param. |
| 56 | + |
| 57 | + void test() { |
| 58 | +// ^^^^ definition [..] test(49f6e7a06ebc5aa8). |
| 59 | + (void)zero<int>; |
| 60 | +// ^^^^ reference [..] zero. |
| 61 | + |
| 62 | + (void)C<int>().mono; |
| 63 | +// ^ reference [..] C# |
| 64 | +// ^^^^ reference [..] C#mono. |
| 65 | + (void)C<int>().from_param; |
| 66 | +// ^ reference [..] C# |
| 67 | +// ^^^^^^^^^^ reference [..] C#from_param. |
| 68 | + |
| 69 | + (void)C<int>::static_mono; |
| 70 | +// ^ reference [..] C# |
| 71 | +// ^^^^^^^^^^^ reference [..] C#static_mono. |
| 72 | + (void)C<int>::static_const_mono; |
| 73 | +// ^ reference [..] C# |
| 74 | +// ^^^^^^^^^^^^^^^^^ reference [..] C#static_const_mono. |
| 75 | + (void)C<int>::static_from_param; |
| 76 | +// ^ reference [..] C# |
| 77 | +// ^^^^^^^^^^^^^^^^^ reference [..] C#static_from_param. |
| 78 | + (void)C<int>::static_const_from_param; |
| 79 | +// ^ reference [..] C# |
| 80 | +// ^^^^^^^^^^^^^^^^^^^^^^^ reference [..] C#static_const_from_param. |
| 81 | + (void)C<int>::static_templated<int>; |
| 82 | +// ^ reference [..] C# |
| 83 | +// ^^^^^^^^^^^^^^^^ reference [..] C#static_templated. |
| 84 | + } |
0 commit comments