Dear Haskellers, Why can't field labels have the same name in different types?
Here's some actual code on finite state automata I'm working on: > data BMC > = BMC { node :: !Int, > threshold :: !Float, > edge0 :: BMC, > edge1 :: BMC } > data BFSM > = BFSM { bfsmnode :: !Int, > bfsmstate :: Maybe Bool, > bfsmoutput :: [Bool], > bfsmedge0 :: BFSM, > bfsmedge1 :: BFSM } What I really want is to use the same field labels of node, edge0, and edge1 in the BFSM type, but I can't because otherwise I get the following in hugs: ERROR xxx - Repeated definition for selector "edge0" I'm not an expert on programming languages, but doesn't it seem that Haskell, as a strongly-typed language, should not have any problem distinguishing the field labels of different datatypes? Kim-Ee _______________________________________________ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell