Check-in [e3243a6107]

Bounty program for improvements to Tcl and certain Tcl packages.
Tcl 2019 Conference, Houston/TX, US, Nov 4-8
Send your abstracts to [email protected]
or submit via the online form by Sep 9.

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Comment:Got the description of classvariable wrong.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: e3243a61075671db983eda852718785091ea20872deba33b0c005c372cbaa9c9
User & Date: dkf 2018-06-17 16:52:54
Added TIP 511 for Christian Werner, who is having problems with his fossil login check-in: 063fc0cf1c user: dkf tags: trunk
Got the description of classvariable wrong. check-in: e3243a6107 user: dkf tags: trunk
fixed code error check-in: 51aba99441 user: rene tags: trunk
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to tip/

    37     37   subclasses can be instantiated.
    38     38   
    39     39   ## New Definitions
    40     40   
    41     41   The `classmethod` class definition creates a method that can be used when
    42     42   invoked against its defining class or any of its subclasses.
    43     43   
    44         -The `classvariable` class definition creates a variable that exists in a
    45         -class's namespace and which is linked into any instance of that class
    46         -(including instances of subclasses); setting the variable with that name from
    47         -any of those instances or from the class will result in changes that can be
    48         -observed from all instances of that class.
    49         -
    50     44   The `initialise` class definition evaluates a script in a context where it can
    51     45   access the class's namespace, allowing for easier initialisation of a class
    52     46   than simply overriding its constructor.
    53     47   
    54     48   ## New Helper Commands
    55     49   
    56     50   The `callback`/`mymethod` command, available within methods, takes the name of
    57     51   a method and zero-or-more arguments and returns a script fragment that will
    58     52   allow that method easy to invoke from a callback (e.g., a variable `trace`,
    59     53   `chan event` callback, or Tk event binding). The command will be available
    60     54   with both names.
           55  +
           56  +The `classvariable` command, available within methods, binds a local variable
           57  +to a variable within the namespace of the class that defined the method.
    61     58   
    62     59   The `link` command, available within methods, creates a binding for methods
    63     60   so that calling the command with the given name is equivalent to calling
    64     61   `my $name` instead. It can link multiple methods with one call, one per
    65     62   argument, and those created commands can be renamed without losing the link;
    66     63   if an argument is a two-element list, the first element is the name of the
    67     64   method and the second is the name of the command (which will be resolved