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

           Summary: Comparison of different enums
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: diagnostic
          Severity: enhancement
          Priority: P2
         Component: DMD
        AssignedTo: nob...@puremagic.com
        ReportedBy: bearophile_h...@eml.cc


--- Comment #0 from bearophile_h...@eml.cc 2011-06-29 17:06:51 PDT ---
I think comparisons of different enums may hide bugs (this compiles with no
errors on DMD 2.053):


enum Foo { x }
enum Bar { y }
void main() {
    auto b = Foo.x == Bar.y;
}


A less visible to spot case:

enum { X }
enum { Y }
void main() {
    auto b = X == Y;
}


See also bug 3999

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

Reply via email to