Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] Diff of /smlnj-lib/trunk/XML/xml-lexer.lex.sml
ViewVC logotype

Diff of /smlnj-lib/trunk/XML/xml-lexer.lex.sml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 5258, Sun Jun 2 04:14:53 2019 UTC revision 5259, Sun Jun 2 04:15:59 2019 UTC
# Line 2  Line 2 
2    
3      datatype yystart_state =      datatype yystart_state =
4  COM | TAG | LIT1 | LIT2 | INITIAL | DOCTYPE  COM | TAG | LIT1 | LIT2 | INITIAL | DOCTYPE
5        local
6    
7      structure UserDeclarations =      structure UserDeclarations =
8        struct        struct
9    
# Line 24  Line 26 
26  (* trim m characters from the left and n characters from the right *)  (* trim m characters from the left and n characters from the right *)
27    fun trim (m, ss, n) = Substring.string(Substring.triml m (Substring.trimr n ss))    fun trim (m, ss, n) = Substring.string(Substring.triml m (Substring.trimr n ss))
28    
   
29        end        end
30    
     local  
31      datatype yymatch      datatype yymatch
32        = yyNO_MATCH        = yyNO_MATCH
33        | yyMATCH of ULexBuffer.stream * action * yymatch        | yyMATCH of ULexBuffer.stream * action * yymatch
# Line 105  Line 105 
105                  (fn (~1, _, oldMatches) => yystuck oldMatches                  (fn (~1, _, oldMatches) => yystuck oldMatches
106                    | (curState, strm, oldMatches) => let                    | (curState, strm, oldMatches) => let
107                        val (transitions, finals') = Vector.sub (yytable, curState)                        val (transitions, finals') = Vector.sub (yytable, curState)
108                        val finals = map (fn i => Vector.sub (actTable, i)) finals'                        val finals = List.map (fn i => Vector.sub (actTable, i)) finals'
109                        fun tryfinal() =                        fun tryfinal() =
110                              yystuck (yyactsToMatches (strm, finals, oldMatches))                              yystuck (yyactsToMatches (strm, finals, oldMatches))
111                        fun find (c, []) = NONE                        fun find (c, []) = NONE

Legend:
Removed from v.5258  
changed lines
  Added in v.5259

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0