Changes between Version 28 and Version 29 of Records


Ignore:
Timestamp:
Jan 7, 2012 11:29:09 PM (2 years ago)
Author:
GregWeber
Comment:

link to new page

Legend:

Unmodified
Added
Removed
Modified
  • Records

    v28 v29  
    3535 
    3636 1. Overloading: polymorphic selection & update; see [wiki:Records/OverloadedRecordFields] 
    37  2. Namespacing: simple name-spacing & type resolution; see below 
     37 2. Namespacing: simple name-spacing & type resolution; see [wiki:Records/NameSpacing] 
    3838 
    3939'''Are there any other approaches?''' 
     
    4848 
    4949and that can work for both Record and `RecordClash` because they both have a field `a`. 
    50 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 (whereas there are still questions as to the feasibility of Overloading). Overloading has seen downsides in practice. In the words of the Frege author, who abandoned Overloading: 
     50With 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: 
    5151 
    5252    * 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.