Index: generic/predefined.h =================================================================== diff -u -r670151ba40e8da27625ed679f2d3ff58d1763239 -r4a91216d0624226fb9a64de97feccc84cc79df79 --- generic/predefined.h (.../predefined.h) (revision 670151ba40e8da27625ed679f2d3ff58d1763239) +++ generic/predefined.h (.../predefined.h) (revision 4a91216d0624226fb9a64de97feccc84cc79df79) @@ -453,6 +453,8 @@ "set setterParam ${:name}}\n" "::xotcl::setter ${:domain} {*}$perObject $setterParam}}\n" "::xotcl::Attribute mixin add ::xotcl::Attribute::Optimizer\n" +"::xotcl2::Object method attribute {spec {-slotclass ::xotcl::Attribute} {initblock \"\"}} {\n" +"$slotclass createFromParameterSyntax [self] -initblock $initblock {*}$spec}\n" "::xotcl2::Class public method parameter arglist {\n" "foreach arg $arglist {\n" "::xotcl::Attribute createFromParameterSyntax [self] {*}$arg}\n" @@ -470,15 +472,15 @@ "if {![::xotcl::is $value metaclass]} {\n" "error \"expected metaclass but got \\\"$value\\\" for parameter $name\"}\n" "return $value}}\n" -"::xotcl2::Class create ::xotcl::ScopedNew -superclass ::xotcl2::Class -parameter {\n" -"{withclass ::xotcl2::Object}\n" -"container}\n" -"::xotcl::ScopedNew protected method init {} {\n" +"::xotcl2::Class create ::xotcl::ScopedNew -superclass ::xotcl2::Class {\n" +":attribute {withclass ::xotcl2::Object}\n" +":attribute container\n" +":protected method init {} {\n" ":public method new {-childof args} {\n" "::xotcl::importvar [::xotcl::self class] {container object} withclass\n" "if {![::xotcl::is $object object]} {\n" "$withclass create $object}\n" -"eval ::xotcl::next -childof $object $args}}\n" +"eval ::xotcl::next -childof $object $args}}}\n" "::xotcl2::Object public method contains {\n" "{-withnew:boolean true}\n" "-object\n" @@ -498,10 +500,10 @@ "namespace eval $object $cmds}}\n" "::xotcl2::Class forward slots %self contains \\\n" "-object {%::xotcl::dispatch [::xotcl::self] -objscope ::subst [::xotcl::self]::slot}\n" -"::xotcl2::Class create ::xotcl::CopyHandler -parameter {\n" -"{targetList \"\"}\n" -"{dest \"\"}\n" -"objLength} {\n" +"::xotcl2::Class create ::xotcl::CopyHandler {\n" +":attribute {targetList \"\"}\n" +":attribute {dest \"\"}\n" +":attribute objLength\n" ":method makeTargetList {t} {\n" "lappend :targetList $t\n" "if {[::xotcl::is $t object]} {\n"