| 1 |
/* Verify colorization of the output of -fdiagnostics-show-template-tree, |
| 2 |
and within the %H and %I format codes. |
| 3 |
Doing so requires a plugin; see the comments in the plugin for the |
| 4 |
rationale. */ |
| 5 |
|
| 6 |
// { dg-options "-fdiagnostics-show-template-tree -fdiagnostics-color=always" } |
| 7 |
|
| 8 |
template<typename> struct vector {}; |
| 9 |
template<typename, typename> struct map {}; |
| 10 |
|
| 11 |
void fn_1(vector<int>); |
| 12 |
void fn_2(map<int, int>); |
| 13 |
|
| 14 |
void test () |
| 15 |
{ |
| 16 |
fn_1 (vector<double> ()); |
| 17 |
/* { dg-begin-multiline-output "" } |
| 18 |
could not convert '[01m[Kvector<double>()[m[K' from '[01m[Kvector<[01;32m[Kdouble[m[K>[m[K' to '[01m[Kvector<[01;34m[Kint[m[K>[m[K' |
| 19 |
vector< |
| 20 |
[[01;32m[Kdouble[m[K != [01;34m[Kint[m[K]> |
| 21 |
{ dg-end-multiline-output "" } */ |
| 22 |
|
| 23 |
fn_2 (map<int, double>()); |
| 24 |
/* { dg-begin-multiline-output "" } |
| 25 |
could not convert '[01m[Kmap<int, double>()[m[K' from '[01m[Kmap<[...],[01;32m[Kdouble[m[K>[m[K' to '[01m[Kmap<[...],[01;34m[Kint[m[K>[m[K' |
| 26 |
map< |
| 27 |
[...], |
| 28 |
[[01;32m[Kdouble[m[K != [01;34m[Kint[m[K]> |
| 29 |
{ dg-end-multiline-output "" } */ |
| 30 |
} |