Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/vis12/src/compiler/parser/parser.sml
ViewVC logotype

Diff of /branches/vis12/src/compiler/parser/parser.sml

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

revision 435, Tue Oct 19 13:14:20 2010 UTC revision 1116, Thu May 5 04:49:02 2011 UTC
# Line 19  Line 19 
19    (* error function for lexers *)    (* error function for lexers *)
20      fun lexErr errStrm (pos, msg) = Error.errorAt(errStrm, (pos, pos), msg)      fun lexErr errStrm (pos, msg) = Error.errorAt(errStrm, (pos, pos), msg)
21    
22      (* map tokens to strings *)
23        fun tokToString (DiderotTokens.ID x) = Atom.toString x
24          | tokToString (DiderotTokens.STRING s) = concat["\"", String.toCString s, "\""]
25          | tokToString (DiderotTokens.FLOAT f) = FloatLit.toString f
26          | tokToString (DiderotTokens.INT i) = IntInf.toString i
27          | tokToString tok = DiderotTokens.toString tok
28    
29    (* error function for parsers *)    (* error function for parsers *)
30      val parseErr = Error.parseError DiderotTokens.toString      val parseErr = Error.parseError tokToString
31    
32    (* parse a file, returning a parse tree *)    (* parse a file, returning a parse tree *)
33      fun parseFile (errStrm, file) = let      fun parseFile (errStrm, file) = let

Legend:
Removed from v.435  
changed lines
  Added in v.1116

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