summaryrefslogtreecommitdiff
path: root/src/compiler/GF/Grammar
AgeCommit message (Collapse)Author
2012-12-19GF.Grammar.Lookup: new function lookupResDefLochallgren
It's like lookupResDef but it includes a source location in the output.
2012-12-11partial evaluator workhallgren
* Evaluate operators once, not every time they are looked up * Remember the list of parameter values instead of recomputing it from the pattern type every time a table selection is made. * Quick fix for partial application of some predefined functions.
2012-11-23Fix a prededence bug in GF grammar pretty printerhallgren
The pretty printer produced mkDet pre {"a"; "an" / vowel} Sg which is not accepted by the parser. The parser assigns pre { ... }, to prededence level 4, and this is now reflected in the pretty printer, so it prints mkDet (pre {"a"; "an" / vowel}) Sg (This caused a problem in GFSE since it parsers pretty printed grammars...)
2012-11-07GF.Grammar.PatternMatch: relax overly restrictive type signatureshallgren
2012-10-25GF.Grammar.Macros: add function collectPattOphallgren
collectPattOp :: (Patt -> [a]) -> Patt -> [a]
2012-10-24GF.Grammar.Macros: add function composPattOphallgren
For Patt, analogous to composOp for Term.
2012-09-28GF shell, show_operations: nicer looking types for linearization functionshallgren
Adding a lock field to the result type of linearization functions. TODO: figure out how to add a lock field to the argument types too.
2012-09-27GF shell, show_operations: also show the types of linearization functionshallgren
This is a simple change in GF.Grammar.Lookup.allOpers, which is used only in the implementation of the show_operations command in the shell. This is useful when importing a concrete syntax (like LexiconEng) as a resource. However, the types don't always look as nice as I hoped...
2012-08-29Use nub' instead of nub in some places, remove some unused nub importspeter.ljunglof
2012-06-26Report many type errors instead of stopping after the first onehallgren
In GF.Compile.CheckGrammar, use a new topological sorting function that groups independent judgements, allowing them all to be checked before continuing or reporting errors.
2012-06-25printing ResValue judgements as comments, to provide useful information when ↵aarne
a conflict is found between parameter constructors
2012-06-15Add file name to error message when reading a bad .gfo file (in some cases)hallgren
This turns error messages like gf: too few bytes. Failed reading at byte position 1 gf: /some/path/somefile.gfo: too few bytes. Failed reading at byte position 1 but a better fix would be to ignore bad .gfo files and compile from source. The problem is the way this decision is made in GF.Compile.ReadFiles.selectFormat...
2012-05-04alex 3 incompatibility workaroundhallgren
As a temporary workaround, alex is no longer invoked automatically when building with cabal. Developers who want to modify the lexer need to run alex on Lexer.x manually and record the modified Lexer.hs. src/compiler/GF/Grammar/lexer/Lexer.x -- hidden from cabal src/compiler/GF/Grammar/Lexer.hs -- update it manually
2012-02-24the Predef function eqVal to compare equality of parameter valuesaarne
2012-02-22gfse: experimental support for editing concrete syntax in text modehallgren
2011-12-02missing cases in GF.Grammar.Binarykr.angelov
2011-11-30more stuff in the new type checkerkr.angelov
2011-11-29Sketch of the new type checker for the concrete syntax. Enabled only with ↵kr.angelov
-new-comp
2011-11-15fix in the versioning of the .gfo fileskr.angelov
2011-11-15now we store version number in every .gfo file. If the file is compiled with ↵kr.angelov
different compiler then we simply recompile it.
2011-11-15now the pretty printer in GF has a new mode called Internal. This is the ↵kr.angelov
most detailed mode and it can print even things that are not in the GF syntax. For example PMCFG snippets and indirections.
2011-11-15more structured format for errors and warnings from the compilerkr.angelov
2011-11-10Now PMCFG is compiled per module and at the end we only link it. The new ↵kr.angelov
compilation schema is few times faster.
2011-11-02merge GF.Infra.Modules and GF.Grammar.Grammar. This is a preparation for the ↵kr.angelov
separate PGF building
2011-11-02Now the compiler maintains more precise information for the source locations ↵kr.angelov
of the different definitions. There is a --tags option which generates a list of all identifiers with their source locations.
2011-10-20Introduce an explicit error value in the Term typehallgren
This makes it easier to treat run-time errors (e.g. caused by calls to Predef.error) in a way that is more typical for a lazy functional language.
2011-10-20Some experiments with PSeq (left commented out)hallgren
2011-09-26don't count app nodes in term sizeaarne
2011-09-24bug fixes in code size analysisaarne
2011-09-22change the precedence for the left argument of ->kr.angelov
2011-09-22the sd -size command now shows the size of all code needed for defining an operaarne
2011-09-22documented the ss commandaarne
2011-09-21statistics on grammar size in terms of constructorsaarne
2011-09-21commands ss to show source, and sd to show the dependencies of a constantaarne
2011-09-20module for analysing source grammarsaarne
2011-09-20command ss to show source (including gfo) in text; to be extendedaarne
2011-09-07GF.Grammar.Macros: simplify composOp and composSafeOphallgren
2011-09-01GF.Grammar.*: generalized the type of some functions that can not fail from ↵hallgren
the Err monad to arbitrary monads
2011-08-31GF.Infra.Modules: minor tweakshallgren
Still keeping the modules both in a list and in a finite map. The overhead is smaller than I initially thought.
2011-08-30GF.Infra.Modules: keep the modules of a grammar in a finite map instead of a ↵hallgren
list This speeds up the compilation of PhrasebookFin.pgf by 12%, mosly by speeding up calls to lookupModule in calls from lookupParamValues, in calls from allParamValues. The invariant "modules are stored in dependency order" is no longer respected! But the type MGrammar is now abstract, making it easier to maintain this or other invariants in the future.
2011-08-30GF.Grammar.Lookup: added function lookupQIdentInfohallgren
+ Avoids some code duplication by combinging lookupModule and lookupIdentInfo. + Also removed lookupIdentInfo from export list, since it is not used anywhere else.
2011-08-30PatternMatch.hs: commented out suspicious unused function varsOfPatthallgren
2011-07-21GenIP, GenRP in Extra and any_Quant in ExtraEngaarne
2011-06-02Predef functions toUpper, toLower, isUpperaarne
2011-03-12make it possible to override opers defined in an interface by syntax ↵aarne
'instance Foo of Bar - [f,g,h]'
2011-03-03overloaded opers included in sorting of judgementsaarne
2011-02-28the command show_operations to inspect opers in scopeaarne
2010-12-14option cc -list addedaarne
2010-12-10preparing resource api for multilingual documentationaarne
2010-11-15bugfix for the abstract operationskrasimir