You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So this seems to be related to deduction guides somehow. Could it be that we synthesize a new lambda type for CTAD and happen to mix it with types that we also creates during substitution?
cc @hokein who recently worked on CTAD, in case he has any ideas.
The text was updated successfully, but these errors were encountered:
The following code fails to compile (see https://godbolt.org/z/zTf49f9oe):
```cpp
template <typename MakeValue = decltype([] { return 1; })>
class Example {
public:
using Result = decltype(MakeValue()());
explicit Example(MakeValue&& make_value = {})
: make_value_(make_value) {}
Adding an empty template argument list makes the error go away (see https://godbolt.org/z/dz7eMaM54):
```cpp
auto example = Example<>();
So this seems to be related to deduction guides somehow. Could it be that we synthesize a new lambda type for CTAD and happen to mix it with types that we also creates during substitution?
cc @hokein who recently worked on CTAD, in case he has any ideas.
The following code fails to compile (see https://godbolt.org/z/zTf49f9oe):
Adding an empty template argument list makes the error go away (see https://godbolt.org/z/dz7eMaM54):
auto example = Example<>();
So this seems to be related to deduction guides somehow. Could it be that we synthesize a new lambda type for CTAD and happen to mix it with types that we also creates during substitution?
cc @hokein who recently worked on CTAD, in case he has any ideas.
The text was updated successfully, but these errors were encountered: