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