From: Duncan C. <dun...@us...> - 2004-11-13 17:27:07
|
Update of /cvsroot/gtk2hs/gtk2hs/tools/c2hs/c2hs/chs In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15642/c2hs/chs Modified Files: CHS.hs Log Message: add Axel's --precomp patches with a binary serialisation framework derived from the one used in ghc. This required makeing Position a proper data type. Also converted to using Data.FiniteMap rather than the CTK FiniteMaps module. Index: CHS.hs =================================================================== RCS file: /cvsroot/gtk2hs/gtk2hs/tools/c2hs/c2hs/chs/CHS.hs,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -u -d -r1.1.1.1 -r1.2 --- CHS.hs 13 Nov 2004 16:42:35 -0000 1.1.1.1 +++ CHS.hs 13 Nov 2004 17:26:52 -0000 1.2 @@ -98,7 +98,7 @@ import Monad (when) -- Compiler Toolkit -import Common (Position, Pos(posOf), nopos, isBuiltinPos) +import Common (Position(Position), Pos(posOf), nopos, isBuiltinPos) import Errors (interr) import Idents (Ident, identToLexeme, onlyPosIdent) @@ -327,7 +327,7 @@ -- parse -- traceInfoParse - mod <- parseCHSModule (fullname, 1, 1) contents + mod <- parseCHSModule (Position fullname 1 1) contents -- check for errors and finalize -- @@ -401,7 +401,7 @@ showFrags _ _ [] = id showFrags pureHs state (CHSVerb s pos : frags) = let - (fname, line, _) = pos + (Position fname line _) = pos generated = isBuiltinPos pos emitNow = state == Emit || (state == Wait && not (null s) && head s == '\n') |