Diff for /parser3/tests/261.html between versions 1.2 and 1.7

version 1.2, 2010/10/24 21:41:25 version 1.7, 2023/09/28 12:41:58
Line 1 Line 1
 @main[]  @main[]
   
   $void_methods[^reflection:methods[void]]
   $string_methods[^reflection:methods[string]]
   
   ^if($void_methods != $string_methods){
           String has ^string_methods._count[] while void has ^void_methods._count[].
   }
   
   $s[]
   $w[     ]
   $v[$void]
   
   Empty string vs void:
   
   Json: ^json:string[$s] vs ^json:string[$v]
   Json (void as string): ^json:string[$s;$.void[string]] vs ^json:string[$v;$.void[string]]
   Json (void as null): ^json:string[$s;$.void[null]] vs ^json:string[$v;$.void[null]]
   Length: ^s.length[] vs ^v.length[]
   Double: ^s.double(0) vs ^v.double(0)
   Base64: "^s.base64[]" vs "^v.base64[]"
   Hash compatibility: "$s.key" "$w.key" "$v.key"
   More hash compatibility: "^b[^s.contains[key]]" "^b[^w.contains[key]]" "^b[^w.contains[key]]"
   Methods are not visible: "^show[$s.length]" "^show[$w.length]" "^show[$v.length]"
   
   Non-empty or whitespace string not hash compatible: ^try-catch{
           $s[string]
           $s.key
   }
   Absent method empty string error: ^try-catch{
           $s[]
           ^s.something[]
   }
   Absent method void error: ^try-catch{
           ^v.something[]
   }
   Absent method non-empty string error: ^try-catch{
           $s[string]
           ^s.something[]
   }
   
   ^string_methods.foreach[k;v]{
           ^if(!^void_methods.contains[$k]){
                   String method $k absent in void
           }
   }
   
   @b[v]{
   ^if($v){true}{false}
   
 $void_methods[^reflection:methods[void]]  @show[v]
 $string_methods[^reflection:methods[string]]  $v.CLASS_NAME
   
 ^if($void_methods != $string_methods){  
         String has ^string_methods._count[] while void has ^void_methods._count[].  
 }  
   
 $s[]  
 $v[$void]  
   
 Empty string vs void:  
   
 Json: ^json:string[$s] vs ^json:string[$v]  
 Length: ^s.length[] vs ^v.length[]  
 Double: ^s.double(0) vs ^v.double(0)  
 Base64: "^s.base64[]" vs "^v.base64[]"  
 Hash compatibility: "$s.key" "$v.key"  
   
 Non-empty string: ^try{  
         $s[string]  
         $s.key  
 }{  
         $exception.handled(1)  
         has no hash compatibility  
 }  
   
 ^string_methods.foreach[k;v]{  
         ^if(!($v.$k is 'junction')){  
                 String method $k absent in void  
         }  
 }  

Removed from v.1.2  
changed lines
  Added in v.1.7


E-mail: