Diff for /gforth/regexp-test.fs between versions 1.20 and 1.21

version 1.20, 2010/12/27 21:46:25 version 1.21, 2010/12/27 22:39:38
Line 187  s" bla 45296s fasel 117s blubber" str= [ Line 187  s" bla 45296s fasel 117s blubber" str= [
   
 s" (bla) 12:34:56 (fasel) 00:01:57 (blubber)" 2dup type hms>s,del() ."  -> " type cr  s" (bla) 12:34:56 (fasel) 00:01:57 (blubber)" 2dup type hms>s,del() ."  -> " type cr
   
   \ more tests from David K├╝hling
   
   require test/ttester.fs
   
   : underflow1  ( c-addr u -- flag )
      (( {{
            {{ ` - || }} \d
            || \d
         }} )) ;
   T{ s" -1dummy" underflow1 -> true }T
   
   : underflow2  ( -- )
      (( \( {{ \s {** \s **} 
            || =" /*" // =" */"
            || =" //" {** \d **} }} \) )) ;
   T{ s" /*10203030203030404*/   " underflow2 -> true }T
   T{ pad 0 underflow2 -> false }T
   
   charclass [*] '* +char
   charclass [*/] '* +char '/ +char
   
   : underflow3  ( -- )
      ((
         =" /*"
         \( {** {{ [*] -c? || ` * [*/] -c? }}  **} \)
         {++ ` * ++} ` /
      )) ;
   
   \ this still seems to be too complicated
   T{ s" /*10203030203030404*/   " underflow3 -> true }T
   \1 type cr
   
   : underflow4  ( -- )
      (( \( {{ {** \d **} || {** \d **} }} \d \) )) ;
   
   T{ s" 0  " underflow4 -> true }T
   
 script? [IF] bye [THEN]  script? [IF] bye [THEN]

Removed from v.1.20  
changed lines
  Added in v.1.21


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>