Do not generate detailed candidates / constraint error msg in speculative contexts

Unless the error is actually going to be printed.
This commit is contained in:
Geod24 2022-07-11 15:07:11 +02:00 committed by The Dlang Bot
parent 25799d3841
commit a2d2c4b31e
2 changed files with 19 additions and 9 deletions

View file

@ -1,8 +1,11 @@
/*
TEST_OUTPUT:
---
fail_compilation/ice11856_1.d(13): Error: none of the overloads of template `ice11856_1.g` are callable using argument types `!()(A)`
fail_compilation/ice11856_1.d(11): Candidate is: `g(T)(T x)`
fail_compilation/ice11856_1.d(16): Error: none of the overloads of template `ice11856_1.g` are callable using argument types `!()(A)`
fail_compilation/ice11856_1.d(14): Candidate is: `g(T)(T x)`
with `T = A`
must satisfy the following constraint:
` is(typeof(x.f()))`
---
*/
struct A {}