Changeset 1042 for trunk/lang/tcl/scripts/library.tcl
- Timestamp:
- Jun 10, 2008, 6:52:04 PM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/lang/tcl/scripts/library.tcl
r1018 r1042 347 347 } 348 348 set node [$node parentNode] 349 if {$node == ""} { 350 return "" 351 } 349 352 350 353 switch -- $params(-as) { … … 453 456 } 454 457 default { 455 error "bad flavor \"$params(-as)\": should be component, id, object, type"458 error "bad flavor \"$params(-as)\": should be component, id, object, path, type" 456 459 } 457 460 } … … 502 505 } 503 506 if {$params(-decode) == "yes"} { 504 return [Rappture::encoding::decode [string trim [$node text]]]507 return [Rappture::encoding::decode -- [string trim [$node text]]] 505 508 } else { 506 509 return [string trim [$node text]] … … 543 546 } 544 547 } 545 if {[llength $args] > 2} {548 if {[llength $args] < 1 || [llength $args] > 2} { 546 549 error "wrong # args: should be \"put ?-append bval? ?-id num? ?-type string|file? ?-compress bval? ?path? string\"" 547 550 } … … 563 566 564 567 if {$params(-compress) || [Rappture::encoding::is binary $str]} { 565 set str [Rappture::encoding::encode $str]568 set str [Rappture::encoding::encode -- $str] 566 569 } 567 570
Note: See TracChangeset
for help on using the changeset viewer.