Changes between Version 4 and Version 5 of Records/DeclaredOverloadedRecordFields/COmpareSORF


Ignore:
Timestamp:
Feb 20, 2012 9:48:30 PM (2 years ago)
Author:
guest
Comment:

afterthought re Proxy types vs Kinds

Legend:

Unmodified
Added
Removed
Modified
  • Records/DeclaredOverloadedRecordFields/COmpareSORF

    v4 v5  
    11 
    2 = DORF -- comparison to SORF = 
     2= DORF -- comparison to SORF (and to TDNR) = 
    33 
    44This is a brief point-by-point comparison to 
     
    1919In contrast: "The [SORF] proposal ... doesn't allow label names to be scoped: if one module internally uses "field" as a label name then another module can break the abstraction by using the same string "field"." SPJ goes on to discuss a work-round which he sees as "ugly", and concludes "we need scoped instances". DORF does not need any innovations around instances or type inference. 
    2020 
    21 === Should `get` have a Proxy argument? === 
     21'''Wild afterthought:'''  
     22 * DORF __does__ need to apply module control/representation hiding to the field selector function. 
     23 * But if that's controlled, perhaps it doesn't need to control the Proxy type(?) 
     24 * (In fact, the Proxy type is a bit of an annoyance, with a shadowy existence just out of sight from the application programmer, except for the need to export/import it.) 
     25 * Perhaps we could use Kinds instead, and take advantage of the inability to control their scope: 
     26   * Kinds could be just used, not declared. 
     27   * They could be `String` Kinds or some more abstract/compact/hidden representation. 
     28 
     29 
     30=== Should `get` have a Proxy argument? (and should `set` ?) === 
    2231 
    2332"This choice does not make a major difference either way." [SPJ]. DORF likewise doesn't care. The prototype does use a Proxy argument, because it's implemented using types not Kinds, and GHC doesn't (yet) have type application.