parse is very powerfull but still kills me with spacer:

>> parse "asergd" lib-name  
== true
>> parse "LIB1"  lib-type
== true

so the 2 elements matches the 2 single rules.
but pout together they don't :

>> parse "asergd LIB1" [lib-name lib-type]
== false
>> probe parse "asergd LIB1" [lib-name lib-type]
false
== false
>> parse/all "asergd LIB1" [lib-name lib-type]
== false

but the white space means trouble:

>> parse/all "asergd LIB1" [lib-name " " lib-type]
== true

why one matches with extra white space and not the other ?
>> parse "LIB1 "  lib-type                        
== false
>> parse "asergd " lib-name                          
== true
>> parse " asergd " lib-name  
== true

lib-name: [name]
name: [ some symbol ]
lib-type: [ "LIB1" | "LIB2" ]
symbol: charset [#"0" - #"9" #"A" - #"Z" #"a" -
#"z" #"." #"-" #"_" #"$" #"+" ]



Reply via email to