Changes between Version 34 and Version 35 of Records


Ignore:
Timestamp:
Jan 8, 2012 12:32:40 PM (3 years ago)
Author:
GregWeber
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Records

    v34 v35  
    4646 
    4747and that can work for both `Record` and `RecordClash` because they both have a field `a`. 
    48 With Namespacing this will fail to type check unless the compiler can determine the type of r. The advantage of Namespacing is that the implementation is clear, straightforward, and has already been done (in the Frege language, whereas there are still questions as to the feasibility of Overloading). Overloading has seen other downsides in practice. In the words of the Frege author, who abandoned Overloading: 
     48With Namespacing this will fail to type check unless the compiler can determine the type of r is either `Record` or `RecordClash`. The advantage of Namespacing is that the implementation is clear, straightforward, and has already been done (in the Frege language, whereas there are still questions as to the feasibility of Overloading). Overloading has seen other downsides in practice. In the words of the Frege author, who abandoned Overloading: 
    4949 
    5050    * only very inefficient code could be generated, if you have to access or update a field of some unknown record. In the end, every record type was basically a map.