Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 3257a4016c17f8a5bef792a0df40965c33853282
Ticket: 1993441fffffffffffffffffffffffffffffffff
Lightweight pair type 'cons'
User & Date: ferrieux on 2008-06-14 23:01:50
Changes

  1. icomment:
    Logged In: YES 
    user_id=496139
    Originator: YES
    
    Yes, that was an option I proposed during the discussion of the Cons.
    However, it needs pondering yet, because there are two options:
    
    (a) either keep it as a separate Cons type. In that case, [list $a $b] will violate an "intuitive" contract, saying that an object just created with Tcl_NewListObj() *is* of type tclListType. Maybe this is mild, maybe not, dunno yet. Also, absolutely all list operations must be adapted to handle Cons without shimmering back to List. Some work.
    
    (b) or do all this within the List type. The problem here is that the access to the list's intrep is not abstracted; hence there are dozens of places with hard-coded (List *)xxx->twoPtrValue.Ptr1, and even ->elements and ->elemCount despite the access macros.
    Yet more work :-}
    
    Now if you see an alternative, I'm open (but please identify yourself next time ;-)
    
    
    
  2. login: "ferrieux"
  3. mimetype: "text/plain"
  4. username: "ferrieux"