Index: xotcl/library/xml/xmlRecreatorVisitor.xotcl =================================================================== diff -u -rad8a63234e44a8788efede276e811051ab891fbe -rbb3c756fb47517596b9dbcb4e580aa1212827b41 --- xotcl/library/xml/xmlRecreatorVisitor.xotcl (.../xmlRecreatorVisitor.xotcl) (revision ad8a63234e44a8788efede276e811051ab891fbe) +++ xotcl/library/xml/xmlRecreatorVisitor.xotcl (.../xmlRecreatorVisitor.xotcl) (revision bb3c756fb47517596b9dbcb4e580aa1212827b41) @@ -1,4 +1,4 @@ -# $Id: xmlRecreatorVisitor.xotcl,v 1.3 2005/09/09 21:09:01 neumann Exp $ +# $Id: xmlRecreatorVisitor.xotcl,v 1.4 2006/09/14 06:36:02 neumann Exp $ package provide xotcl::xml::recreatorVisitor 0.9 package require xotcl::xml::parser @@ -19,7 +19,7 @@ # determine nesting depth of an object if the aggregation tree # XMLRecreatorVisitor instproc nestingDepth {obj} { - for {set d 0;set s [$obj info parent]} {$s != "::"} {set s [$s info parent]} { + for {set d 0;set s [$obj info parent]} {$s ne "::"} {set s [$s info parent]} { incr d } return $d @@ -73,7 +73,7 @@ XMLRecreatorVisitor instproc visit objName { my instvar result set c [my getContent $objName] - if {$c != ""} { + if {$c ne ""} { $objName instvar attributes pcdata set ns [$objName resolveNS] set firstAttr 1 @@ -85,7 +85,7 @@ append attrStr "xmlns = \"[$ns set nsArray(xmlns)]\"" } foreach a [$ns array names nsArray] { - if {$a != "xmlns"} { + if {$a ne "xmlns"} { append attrStr [my attrIndent $objName firstAttr] append attrStr "xmlns:${a} = \"[$ns set nsArray($a)]\"" } @@ -104,7 +104,7 @@ } if {[info exists pcdata] && [llength $pcdata]>1 && - [lindex $pcdata 0] == ""} { + [lindex $pcdata 0] eq ""} { append result " " [my pcdataString [lindex $pcdata 1]] } append result [my appendLineFeed $objName] @@ -124,7 +124,7 @@ XMLRecreatorVisitor instproc visitEnd objName { my instvar result set c [$objName content] - if {$c != ""} { + if {$c ne ""} { if {![my hasOnlyAttrs $objName]} { append result [my insertIndent $objName] \n }