[Issue 23116] foreach with opApply infer ref when opApply delegate is templated

d-bugmail at puremagic.com d-bugmail at puremagic.com
Mon May 16 17:28:41 UTC 2022


https://issues.dlang.org/show_bug.cgi?id=23116

--- Comment #3 from Luís Ferreira <contact at lsferreira.net> ---
(In reply to Dennis from comment #2)
> Does inferring ref result in actual behavioral problems?

It is. It should use the available overload. In my case, I have something like:

```
[ParameterStorageClassTuple!Dg].all!(stc => !(stc & STC.ref_))
```

It should fall into the usable case, like it does without templating it.

--


More information about the Digitalmars-d-bugs mailing list