Summary: Confusion between string* and immutable(char)*,
                    related to AA's
           Product: D
           Version: D2
          Platform: Other
        OS/Version: Windows
            Status: NEW
          Keywords: rejects-valid
          Severity: normal
          Priority: P2
         Component: DMD

--- Comment #0 from David Simcha <> 2011-10-13 09:43:59 PDT ---
void doExclude(string exclude) {
    string[string] aa;

    int[] keep;
    foreach(int i, h; ["a", "b"]) {
        auto ptr = h in aa;
        pragma(msg, typeof(ptr));  // string*
        pragma(msg, typeof(*ptr)); // string
        if(*h != exclude) keep ~= i;

test.d(9): Error: incompatible types for ((*cast(immutable(char)*)h) !=
(exclude)): 'immutable(char)' and 'string'

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to