http://d.puremagic.com/issues/show_bug.cgi?id=8557

           Summary: AA error with string[string][]
           Product: D
           Version: unspecified
          Platform: All
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nob...@puremagic.com
        ReportedBy: 10equa...@gmail.com


--- Comment #0 from 1100110 <10equa...@gmail.com> 2012-08-18 01:45:53 PDT ---
string[string][]       Dict;    //sure ok.
alias string[string][] dict;    //Error
void main()
{
    Dict                   = [["Cow":"moo" ],["Duck":"quack"]];//cool
    Dict                  ~=  ["Dog":"woof"];                   //No prob.
assert(Dict==[["Cow":"moo"],["Duck":"quack"],["Dog":"woof"]]);//looks legit
    //dict temp              = [["Cow":"moo" ],["Duck":"quack"]];//Error
    //string[string][] temp2 = [["Cow":"moo" ],["Duck":"quack"]];//Error


    //And My favorite one of all:
    //auto temp2 = [["Cow":"moo"],["Duck":"quack"]];  //Error
    auto temp3 = tuple([["Cow":"moo"]]);//works. Variant as well.
}

With everything commented out, Dict works just fine from way up there.
But Tuple, Variant, tls,
Those are the only way to get this to work.

The specific error it gives is:
Error: Integer constant expected instead of "Cow"

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to