CVS: sml-dist/src/smlnj-lib/Util parser-comb-sig.sml,1.2,1.3 parser-comb.sml,1.3,1.4
Matthias Blume <[email protected]>
| Newsgroups | gmane.comp.lang.sml.smlnj.commits |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/smlnj/sml-dist/src/smlnj-lib/Util
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv27506
Modified Files:
parser-comb-sig.sml parser-comb.sml
Log Message:
added join to parser combinators
Index: parser-comb-sig.sml
===================================================================
RCS file: /cvsroot/smlnj/sml-dist/src/smlnj-lib/Util/parser-comb-sig.sml,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** parser-comb-sig.sml 1 Jun 2000 18:33:57 -0000 1.2
--- parser-comb-sig.sml 4 May 2005 15:31:41 -0000 1.3
***************
*** 46,49 ****
--- 46,50 ----
val option : ('a, 'strm) parser -> ('a option, 'strm) parser
+ val join : ('a option, 'strm) parser -> ('a, 'strm) parser
val token : (char -> bool) -> (string, 'strm) parser
Index: parser-comb.sml
===================================================================
RCS file: /cvsroot/smlnj/sml-dist/src/smlnj-lib/Util/parser-comb.sml,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** parser-comb.sml 27 May 2003 21:54:23 -0000 1.3
--- parser-comb.sml 4 May 2005 15:31:41 -0000 1.4
***************
*** 107,110 ****
--- 107,112 ----
(* end case *))
+ fun join p = bind (p, fn SOME x => result x | NONE => failure)
+
(* parse a token consisting of characters satisfying the predicate.
* If this succeeds, then the resulting string is guaranteed to be
-------------------------------------------------------
This SF.Net email is sponsored by: NEC IT Guy Games.
Get your fingers limbered up and give it your best shot. 4 great events, 4
opportunities to win big! Highest score wins.NEC IT Guy Games. Play to
win an NEC 61 plasma display. Visit http://www.necitguy.com/?r=20