Updated metaprogramming capabilities#779
Draft
david-broman wants to merge 22 commits into
Draft
Conversation
* Update s.t. include is more general * Extract specialize arg dependencies * Add utils to get names of required nodes * Include necessary funcs/cons. in AST * Initial lifting of constructors * Initial compilation of specialize terms * Add more TyCon * Add test where extract fails * Info as dep * Add check if any specialize terms found * Add specialize pass in compilation * Lift names to nosym for now * Add peval def. with env as arg * Rm unnecessary def * Add ident (symbol) handling * Remove unnecessary pat match * Add float/bool/char to liftviatype * Rm whitespace * Change to using dummy names when testing lift * Remove comments * Binding to Var if type not liftable in liftviatype * Add lifting of all patterns * Add lift for tmtype and data ast exps * Add lift of never term * Add some documentation comments * Properly traverse expr * Remove type annot call * Use pevalExpr instead * Rm unnec. println * Fix indentation * Remove dependency * Refactor slightly * Rename * Rename variables * Remove out commented code and fix include * Refactor out the loading of run-time deps from utest-generate
* Refactor str joining to work on generic sequences instead. Also add a subsequence replacement method as well. * Fix comment on subseqReplace
* Start work on JSON serializer generator * Work on serializer generator * Add basic test functionality * Work on JSON serializer genrators * Add support for serializing basic types * Rename jsonLib to lib * New approach * Add support for record types * Partial support for TyCons * Start sketch on variant type serializers * First complete version * Fix deserializer bug * Remove leftover TypeEq stub * Add addJsonSerializers * Add a few more handles on JSON library names * Add missing Some
* Fix partial match bug in subseqReplace * One more test for good measure, with 2 partially matched characters that has to be backtracked on * Just one more test case clearly showing that the replacement is non-iterative, it does not try to replace a replacement.
…miking-lang#774) * Add maxf * Transform constants to variables
* Simplify multiplication of two negative factors * Add CPS style maps and folds * Partial evaluation of seq ops * Make dynamic computions the default case * One-pass folding of let bindings * Handle closures and recursion smarter * Factor out incomplete rec let and lam implementations
* Fix bugs in JSON serializers * Add missing Eval inclusion * Fix type bug
* Add skeleton of monomorphization including tests * Add parts of monomorphization with tests * Add basic monomorphisation support * Update monomorphization * Replace order sensitive test * Handle monomorphization with mutual recursion * Minor fixes to monomorphization * Minor fixes and improvements * Add notes about higher-order polymorphism * Remove monomorphization in main compiler * Fix bug in test code * Fix minor bugs in the monomorphization * Extend todo note of problems with frozen types * Improve monomorphization documentation * Remove constEnv as it is unused * Clarify limitations and handle errors better
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
To be added.