----- enum string value = "foo"; struct A { void test(A a) { auto x = a.value; } } void main() { } ----- $ dmd test.d Error: function expected before (), not "foo" of type string It looks like the compiler attempted to do UFCS on a non-function. The above message is reproduced with: auto x = value(a);
*** Issue 20499 has been marked as a duplicate of this issue. ***
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/18664 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB