Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 0c05c27d5a25c570222f7db97622148d606ab010
Ticket: 3474460fffffffffffffffffffffffffffffffff
targetObject should be optional for oo::copy
User & Date: basilik99 on 2012-01-28 01:58:33
Changes

  1. icomment:
    Because to implement the serialization as I described, STORABLE's WRITE method must be called at each stage. But putting STORABLE as a superclass of classes A, B, C, D and E will not work: only class A will have STORABLE as superclass. Hence, STORABLE's WRITE will be called only once, after A's WRITE.
    
    By copying STORABLE to an unnamed class, TclOO allows each of A, B, C, D and E to inherit from STORABLE, or to be more precise, to a distinct copy of STORABLE.
    
    In short, I wanted the following inheritance tree:
    STORABLE
      \
       A     STORABLE
         \     /
           B     STORABLE
            \    /
             ...     STORABLE
               \    /
                 E
    
    
  2. login: "basilik99"
  3. mimetype: "text/plain"
  4. username: "basilik99"