Index: TODO =================================================================== diff -u -rfa18300f1eee8e1998930245b22982c605c071da -raaced4467cdf9fd24e428c1a319b355fb038412d --- TODO (.../TODO) (revision fa18300f1eee8e1998930245b22982c605c071da) +++ TODO (.../TODO) (revision aaced4467cdf9fd24e428c1a319b355fb038412d) @@ -2081,7 +2081,22 @@ i use usually just 2, 4 are ok as well; we should decide. +- removed method "setter" from nx +- removed method "setter" from migration guide +- nx method "attribute": changed name of nonposarg from "slotclass" to "class" +- fix bug for "C class-object attribute foo" (incorrect forwarder) +- extended regression test + +- doctools: changed "-slotclass" to "-class" +- nx::test: made differences in regression test easier to read + +- serializer: updated serializer to avoid calls to "setter" +- extended regression test + + TODO: +- info method definition for attributes? +- remove "setter" from documentation - check performance implications of value conflict checker Index: doc/next-migration.html =================================================================== diff -u -r09fdaef530d334f8ea065db60b20a644c671e74d -raaced4467cdf9fd24e428c1a319b355fb038412d --- doc/next-migration.html (.../next-migration.html) (revision 09fdaef530d334f8ea065db60b20a644c671e74d) +++ doc/next-migration.html (.../next-migration.html) (revision aaced4467cdf9fd24e428c1a319b355fb038412d) @@ -1041,7 +1041,6 @@ # # method # forward -# setter # alias # attribute # @@ -1122,14 +1121,12 @@ http://www.gnu.org/software/src-highlite -->
# Define setter and getter methods
 
-Class create C {
-  :setter p1 ?value_constraint?
-  :class-object setter p2 ?value_constraint?
-}
+Class create C
+::nsf::setter C p1
+::nsf::setter C -per-object p2
 
-Object create o {
-  :setter p3 ?value_constraint?
-}
+Object create o +::nsf::setter o p3
@@ -1237,7 +1234,7 @@
# Method modifiers orthogonal over all kinds of methods
 #
 # Method-definition-methods:
-#    method, forward, setter, alias, attribute
+#    method, forward, alias, attribute
 
 Class create C {
   :/method-definiton-method/ ...
@@ -1256,7 +1253,7 @@
 ::nx::configure defaultMethodCallProtection true|false can be used to set the default
 call protection for scripted methods, forwarder and aliases, while
 ::nx::configure defaultAttributeCallProtection true|false can set the
-default for attributes and setters.

+default for attributes.

@@ -1511,7 +1508,7 @@ http://www.lorenzobettini.it http://www.gnu.org/software/src-highlite -->
# Set instance variable of object obj to a value via
-# resolver (preferred way: define setter method on obj)
+# resolver (preferred way: define attribute on obj)
 
 /obj/ eval [list set /:varName/ ?value?]
@@ -3762,7 +3759,7 @@ protected method can be only called from an object of that class, while public methods can be called from every object. The method protection can be used to every kind of method, such as e.g. scripted -methods, aliases, forwarders, setters or attributes. For invocations, +methods, aliases, forwarders, or attributes. For invocations, the most specific definition (might be a mixin) is used for determining the protection.

@@ -3869,7 +3866,7 @@ Index: doc/next-migration.txt =================================================================== diff -u -r09fdaef530d334f8ea065db60b20a644c671e74d -raaced4467cdf9fd24e428c1a319b355fb038412d --- doc/next-migration.txt (.../next-migration.txt) (revision 09fdaef530d334f8ea065db60b20a644c671e74d) +++ doc/next-migration.txt (.../next-migration.txt) (revision aaced4467cdf9fd24e428c1a319b355fb038412d) @@ -309,7 +309,6 @@ # # method # forward -# setter # alias # attribute # @@ -378,14 +377,12 @@ ---------------- # Define setter and getter methods -Class create C { - :setter p1 ?value_constraint? - :class-object setter p2 ?value_constraint? -} +Class create C +::nsf::setter C p1 +::nsf::setter C -per-object p2 -Object create o { - :setter p3 ?value_constraint? -} +Object create o +::nsf::setter o p3 ---------------- @@ -468,7 +465,7 @@ # Method modifiers orthogonal over all kinds of methods # # Method-definition-methods: -# method, forward, setter, alias, attribute +# method, forward, alias, attribute Class create C { :/method-definiton-method/ ... @@ -486,7 +483,7 @@ `::nx::configure defaultMethodCallProtection true|false` can be used to set the default call protection for scripted methods, forwarder and aliases, while `::nx::configure defaultAttributeCallProtection true|false` can set the -default for attributes and setters. +default for attributes. === Resolvers @@ -666,7 +663,7 @@ |[source,tcl] ---------------- # Set instance variable of object obj to a value via -# resolver (preferred way: define setter method on obj) +# resolver (preferred way: define attribute on obj) /obj/ eval [list set /:varName/ ?value?] ---------------- @@ -2001,7 +1998,7 @@ protected method can be only called from an object of that class, while public methods can be called from every object. The method protection can be used to every kind of method, such as e.g. scripted -methods, aliases, forwarders, setters or attributes. For invocations, +methods, aliases, forwarders, or attributes. For invocations, the most specific definition (might be a mixin) is used for determining the protection. Index: library/lib/test.tcl =================================================================== diff -u -re23d8c899d52279ea014728565097c244d365fba -raaced4467cdf9fd24e428c1a319b355fb038412d --- library/lib/test.tcl (.../test.tcl) (revision e23d8c899d52279ea014728565097c244d365fba) +++ library/lib/test.tcl (.../test.tcl) (revision aaced4467cdf9fd24e428c1a319b355fb038412d) @@ -124,8 +124,8 @@ puts stderr "[set :name]: ${:msg} ok" } } else { - puts stderr "[set :name]:\tincorrect result for '${:msg}'" - puts stderr "expected:\n'${:expected}', got\n'$r'" + puts stderr "[set :name]:\tincorrect result for '${:msg}', expected:" + puts stderr "'${:expected}', got\n'$r'" puts stderr "\tin test file [info script]" if {[info exists :errorReport]} {eval [set :errorReport]} exit -1 Index: library/nx/nx.tcl =================================================================== diff -u -rb8b81d5258a35f294599bb755a0cc15cf363972b -raaced4467cdf9fd24e428c1a319b355fb038412d --- library/nx/nx.tcl (.../nx.tcl) (revision b8b81d5258a35f294599bb755a0cc15cf363972b) +++ library/nx/nx.tcl (.../nx.tcl) (revision aaced4467cdf9fd24e428c1a319b355fb038412d) @@ -1181,7 +1181,7 @@ :protected method init args {set r [::nsf::next]; :optimize; return $r} :public method optimize {} { - #puts stderr OPTIMIZER-[info exists :incremental] + #puts stderr "OPTIMIZER ${:name} incremental -[info exists :incremental]" if {![info exists :methodname]} {return} if {${:per-object}} { set perObject -per-object