aboutsummaryrefslogtreecommitdiff
path: root/source/lux.lux (unfollow)
Commit message (Collapse)AuthorFilesLines
2015-05-02- Implemented some new macros & functions in lux.lux.Eduardo Julian1-113/+212
- WORKING ON DEBUGGING A COMPILER ERROR: java.lang.IncompatibleClassChangeError
2015-05-02- Finally got find-macro & macro-expand to work... (Note: type-vars bug is ↵Eduardo Julian1-68/+32
still there. Must find & squash). -
2015-05-01- Added existential types via #ExT.Eduardo Julian1-1/+2
- Removed the (now useless) lux.type/is-Type? function.
2015-05-01Optimized the compiler with 2 tweaks:Eduardo Julian1-26/+0
- Compilation units are not longer wrapped inside Expression/Statement variants. - analyse-apply* no longer returns lists.
2015-05-01- Added the lux;seed slot to the compiler state.Eduardo Julian1-6/+35
- Macro declarations are now handled at the compiler-phase instead of the analyser phase to avoid the posibility of trying to declare a yet-uncompiled macro (due to the macro-expansion of defmacro). - Added a makeshift implementation of existential types on top of BoundT (must migrate to a more permanent implementation).
2015-05-01- declare-macro has returned.Eduardo Julian1-694/+464
- Method-invocation special forms now take the wanted method as an unprefixed symbol, instead of as text. - Some fixes in lux.analyser.host. - Lambda analysis now just returns the origin exo-type instead of the endo-type. - Made some changes to the type of the CompilerState.
2015-04-30- Implemented pattern-matching for records.Eduardo Julian1-61/+23
- Added some code to allow variant creation with existential types. (NOTE: Check if it's actually valid) - Modify var cleanup to leave the var as-is if it has been deleted. (NOTE: Need to find out why a variable is left prior to being deleted)
2015-04-29- Made a slight correction to the Syntax type when it comes to records ↵Eduardo Julian1-208/+192
(slot-names are no longer Text, but Syntax). - lux/type;bound? no longer does further derefs to check for bound-ness? - Improved the way 2 type-vars are type-checked. - When cleaning type-vars, the dereffed typed is no longer cleaned again.
2015-04-28- Fixed some errors in lux.lux.Eduardo Julian1-1102/+1294
- Added the ability to export from def. - Added an optimized lambda macro. - Finished record analysis & compilation. - Fixed a bug in tuple, function & record analysis wherein AppT wasn't being performed prior to analysing the expression under analysis. - Fixed several bugs wherein "fail*" was needed but "fail" was used. - Added a case for records in base;show-ast. - Made an improvement for AllT in type;show-type. - Corrected an error in pattern-matching compilation wherein casts weren't being performed to make sure the source datum was of the necessary type for PM. - Removed the (now unnecessary) lux/macro.
2015-04-26- lux/analyser/def has been renamed to lux/analyser/module.Eduardo Julian1-214/+213
- Renamed a few defs in lux.lux. - No more type-test shortcut inside lux/analyser/lux. - Defs are now being classified as either (#ValueD <type>) or (#MacroD <macro>).
2015-04-26Made a correction to lux.lux and the analyser regarding how to handle type-vars.Eduardo Julian1-3/+4
2015-04-26- Macros are no longer declared. Instead, they are automatically detected.Eduardo Julian1-257/+270
2015-04-25- No more Any (Top) and Nothing (Bottom) types.Eduardo Julian1-32/+25
2015-04-25- More accurate AllT environment management by using (Maybe TypeEnv) instead ↵Eduardo Julian1-28/+30
of TypeEnv. The performance of the type-checker also improved thanks to that.
2015-04-23- Fused lux;local-envs & lux;global-envs as lux;envs.Eduardo Julian1-18/+22
2015-04-23- Added a dummy implementation of "export'".Eduardo Julian1-208/+395
- Fixed a bug wherein bool pattern-matching was only considered total if there was a wildcard, despite true & false cases where provided. - Changed the syntax of the jvm-interface special form. - Refactored the lux;writer, lux;eval-ctor & lux;loader fields of the CompilerState into a single data-structure which is now stored under the lux;host field
2015-04-23- Removed analyse-2, as it was redundant.Eduardo Julian1-444/+412
- Fixed several bugs within lux.lux. - Renamed "check'" to ":'" and "coerce" to ":!".
2015-04-19- Fixed several bugs in lux.luxEduardo Julian1-1088/+1258
- Fixed an error in lux.base/analyse-2 - Modified the analyser so the symbols that identify all of the special forms must mandatorily have "" as their prefix. - Fixed a bug in the binary operations at lux.analyser.host wherein the types where being omitted. - Fixed a bug when closing-over variables inside lambda bodies wherein the names of bindings where being stores as (incomparable) arrays, instead of as (comparable) strings.
2015-04-17- Solved the bug wherein type-inferencing was causing computational ↵Eduardo Julian1-208/+188
complexity to explode and cause the compiler to become very slow (solved it by removing type-inference from tuples). - Also removed type-inference from functions/lambdas. - Added a small optimization to improve the efficiency of type-checking by not doing a thorough type-check when a global or local binding has a type variant with the same cases as Type, and it's exo-type is also like this (hopefully, it will never happen that someone will exploit this to make the compiler do something weird...)
2015-04-16- |do bindings are now based on pattern matching (that way, tuple ↵Eduardo Julian1-1219/+1239
destructuring can be done at do). - Patterns are no longer put inside a MatchAC structure, but are instead just moved around as lists. - Code outside of &type can no longer create/delete type-vars directly, but must now rely on with-var & with-vars to manage the life-cycle of type-vars. - Simplified pattern-matching analysis at lux/analyser/case. - The LEFT_APP optimization in check* has been replicated on the other side as RIGHT_APP, to attempt to improve performance of pattern-matching.
2015-04-16- Type-vars can now be deleted and be scoped (through with-var).Eduardo Julian1-163/+160
- Fixed a few bugs with types and pattern-matching. - Fixed a bug wherein primitive-analysis did now unify the primitive type with the exotype. - Modified lambda-analysis so functions subject to universal quantification can manage better the universally-quantified variables.
2015-04-15- Fixed a few type-related bugs.Eduardo Julian1-174/+184
- Variants now need types to be specified both when constructing them as when deconstructing them (in pattern-matching). - Simplified DataT types by no-longer requiring a list of params, so only the tame name is necessary.
2015-04-09- Function names & parameters now take prefixes into account.Eduardo Julian1-39/+39
- Added more cases for totality checking in pattern-matching. - Fixed a bug when type-checking function application that used the exo-type for both the function being applied as to the application itself. - Fixed a few minor bugs scattered around that had to do with wrong number of arguments being passed to functions.
2015-04-08- Renamed exec to |do.Eduardo Julian1-126/+126
- :let within |do now uses |let instead of let. - The analyser now does totality analysis and structures the pattern matching, with the compiler only compiling the generated structures. - Local bindings with case' can now be prefixed arbitrarily. (Note: must do the same with functions).
2015-04-02- Identifiers with just a semi-colon in front now have "lux" as their ↵Eduardo Julian1-920/+1079
module, instead of the local module. (e.g. ;map, #;Cons, ;All) - The type-checker now takes into account 2 types: an exo-type (imposed by outside forces) and an endo-type (generated through inference) - Fixed a few bugs in the analyser and the type-system. - &type/solve* is now the actual type-checker and &type/solve invokes solve* with an empty fixpoint environment. - The exo-type of Statements is Nothing. - variants, tuples and def' are being analyzed properly now.
2015-03-30- Beginning to add type-system + type-inferencer.Eduardo Julian1-920/+1100
- Removed exec, get@' & set@' special forms, as they are not primitive enough as to be part of the language.
2015-03-22- Fixed the bug that caused the infinite look while compiling the file.Eduardo Julian1-1/+1
2015-03-22- Added code-cursors (file-name, line-number, column-number) as metadata on ↵Eduardo Julian1-207/+218
lexer nodes & parser nodes.
2015-03-21- Added the reading-phase and it's associated structure as the mediator ↵Eduardo Julian1-4/+25
between raw source-code and the lexing-phase.
2015-03-21- Added module-name aliasing.Eduardo Julian1-102/+112
2015-03-21[2nd Super Refactoring That Breaks The System: Part 7]Eduardo Julian1-416/+420
- System works correctly once more.
2015-03-20[2nd Super Refactoring That Breaks The System: Part 6]Eduardo Julian1-226/+229
- Corrected more bugs in the system.
2015-03-19[2nd Super Refactoring That Breaks The System: Part 5]Eduardo Julian1-817/+817
- Changed indents to symbols. - Corrected some of the bugs in the system. Many more still awaiting fixes.
2015-03-17[2nd Super Refactoring That Breaks The System: Part 2]Eduardo Julian1-49/+67
- Compiler-state is now using Lux record-format. - Went from Error+Ok to Left+Right.
2015-03-15[2nd Super Refactoring That Breaks The System: Part 1]Eduardo Julian1-119/+191
- Finishing implementing the type-system. - Migrating more of the data-structures used in the compiler to the ones used by Lux itself.
2015-03-10- Added null values as jvm-null.Eduardo Julian1-0/+2
2015-03-10- Modified the compiler so parser syntax tokens are stored in the same ↵Eduardo Julian1-6/+4
format as lux data-structures, to ease communication between the compiler & macros.
2015-03-09- Implemented record compilation, alongside get@' and set@'.Eduardo Julian1-128/+184
- Made a small change in float & double comparisons to make sure NaN < n.
2015-03-08- Implemented comparisons and equalities for int, long, float & double.Eduardo Julian1-418/+464
- The lexer now allows "-" in front of numbers to get negative numbers.
2015-03-08- The implementation of monadic macros is finally finished.Eduardo Julian1-64/+70
2015-03-08- In lux.lux, fixed a bug in the "list" macro that rendered it unusable.Eduardo Julian1-387/+383
- Fixed a bug when compiling lambda instantiation (the bug had to do with compiling the env variables passed to the closure). - Fixed a bug in the lexer wherein the backquote (`) wasn't being recognized.
2015-03-08- Changed once more the syntax of the prefix for host special forms. It's ↵Eduardo Julian1-730/+569
now "jvm-" instead of "jvm;" - Fixed the bug where the same local vars/registers were getting registered more than once and the class-verifier complained. - Fixed a bug where the "end label" for pattern-matching bodies was never inserted. - Simplified the analyser by removing "self" calls and having self be just a local for the "this" object (register 0). - Removed the lambda-folding optimization. - The compiler state now holds and environment for naming globally-scoped lambdas.
2015-03-01Simplified the compiler by using arrays to encode tuples & variants instead ↵Eduardo Julian1-34/+15
of using custom classes for that.
2015-03-01Code compiles again! (although, I had to employ a hack for "fold", as ↵Eduardo Julian1-121/+92
function self-calls are broken). Also fixed several small bugs, including the one that caused ".apply" to never make progress (always returned a function with count 0). Also fixed an issue with scopes that caused class-names to be generated improperly.
2015-03-01[TODO]Eduardo Julian1-44/+18
- For some reason, when I fail at compilation due to mistaken use of tags/variants, I don't get the right error reported. [Fixes] - Solved a problem where stack values weren't being properly cleaned-up when pattern-matching on variants and branch bodies.
2015-03-01- Fixed some bugs with pattern matching and macros.Eduardo Julian1-21/+63
- Simplified the code for handling definitions and macros. - Slightly changed the names of the fields of tuple classes. - Added a (currently empty) optimization phase.
2015-03-01Almost done with the super refactoring.Eduardo Julian1-223/+246
Codebase still needs to be simplified further, though. Also, an explicit optimization phase, between analysis and compilation, must be established.
2015-02-15Super refactoring that breaks the system: Part 4Eduardo Julian1-1/+16
2015-02-10Super refactoring that breaks the system: Part 2Eduardo Julian1-46/+62
2015-02-10Super refactoring that breaks the system: Part 1Eduardo Julian1-261/+747