This code ought to work: mixin template M() { bool opIn_r(int i) { return true; } } struct S { mixin M m; } void main() { S s; assert(5 in s.m); }
*** Issue 12159 has been marked as a duplicate of this issue. ***
See also issue 5158.
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/18744 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB