summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
4 daysrebel-lang: scope: allow assigning fields and array elementsMatthias Schiffer
4 daysscope: introduce LookupError typeMatthias Schiffer
5 daysrebel-parse: implement pattern validationMatthias Schiffer
5 daysrebel-parse: handle more pattern typesMatthias Schiffer
Add support for parsing parentheses, field access and index operations in patterns, and distinguish let and destructuring pattern.
5 daysrebel-parse: add type and pat modes to parse-stringMatthias Schiffer
5 daysrebel-parse: add support for different path rootsMatthias Schiffer
Distinguish relative (unprefixed), absolute (`::` prefix) and section-specific (`recipe::`, `task::`) paths.
5 daysrebel-parse: sort keyword enum variants by nameMatthias Schiffer
5 daysrebel-lang: scope: add helpers for path handlingMatthias Schiffer
6 daysrebel-parse, rebel-lang: remove array length from typesMatthias Schiffer
Tuples are sufficient for fixed-length data. For arrays, the small increase in type safety is not worth the large increase in complexity - both for the typechecker, and the usage of the language. The Coerce parameter of unify() is preserved for now, as it may become useful again for other types like sets.
6 daysrebel-lang: merge ast_stmt_type() into record_type() and execute()Matthias Schiffer
This deduplicates some code and improves type checking.
6 daysrebel-lang: repl: use record_type() on a cloned Context instead of ↵Matthias Schiffer
ast_stmt_type() The whole typechecking will happen in record_type() to avoid duplicating the logic.
6 daysexamples: update recipe example to use let syntaxMatthias Schiffer
6 daysrebel-lang: typing: do not accept _ in expressionsMatthias Schiffer
_ is a pattern, not an expression.
6 daysrebel-parse, rebel-lang: distinguish let statements and simple assignmentsMatthias Schiffer
6 daysrebel-parse, rebel-lang: rename "body" to "block"Matthias Schiffer
6 daysrebel-parse: recipe: actually store fetch block in ASTMatthias Schiffer
6 daysrebel-lang: typing: implement turning an AST Type into a runtime TypeMatthias Schiffer
6 daysrebel-lang: scope: add type namespaceMatthias Schiffer
Create a type namespace that is separate from the value namespace, and initialize it with the basic types that should be in scope by default.
6 daysrebel-parse: ast: typ: allow to distinguish between free and dynamic array ↵Matthias Schiffer
length
6 daysrebel-parse: limit explicit array length specification to u32Matthias Schiffer
6 daysrebel-lang: limit array lengths to u32Matthias Schiffer
Make the supported maximum array length independent of usize.
6 daysrebel-parse: token: reserve "let" and "mut" keywordsMatthias Schiffer
7 daysrebel-parse: replace TypedExpr with TypedPatMatthias Schiffer
7 daysrebel-parse: create separate types to represent typesMatthias Schiffer
7 daysrebel-parse: rename struct field name from key to nameMatthias Schiffer
7 daysrebel-parse: split expr out of ast moduleMatthias Schiffer
7 daysrebel-lang: typing: change function names for expr typesMatthias Schiffer
Be explicit about that these functions handle types of AST expressions, rather than an explicit type specification.
7 daysrebel-lang: distinguish explicit and inferred type of variablesMatthias Schiffer
7 daysrebel-lang: add support str comparisionMatthias Schiffer
7 daysrebel-parse: use phf for faster keyword parsingMatthias Schiffer
7 daysrebel-parse: reserve struct, map and set keywordsMatthias Schiffer
7 daysrebel-lang: typing: use write_str() to format constant stringsMatthias Schiffer
7 daysrebel-lang: value: fix Value enum variant names to match Type variantsMatthias Schiffer
7 daysrebel-lang: typing: remove unused Coerce::NoneMatthias Schiffer
7 daysrebel-lang: typing: rename Coerce::Dynamic to CompareMatthias Schiffer
Compare conveys what this Coercion mode is used for more accurately.
7 daysrebel-lang: typing: Fix function call type checking to use Coerce::AssignMatthias Schiffer
Apply the same rules to call parameters that are used for variable assignment.
7 daysrebel-parse: grammar: order combined assignment operationsMatthias Schiffer
Test for more frequent operations earlier.
7 daysrebel-parse: box expressions in statementsMatthias Schiffer
The size of the statement type has a noticeable effect on performance.
7 daysrebel-parse, rebel-lang: rename Map types to StructMatthias Schiffer
As fields can have different types, calling this a struct is more appropriate, and it frees up the Map name for actual maps that support dynamic lookup and iteration.
7 daysrebel-parse: add support for swapped-add-assign operator (`=+`)Matthias Schiffer
7 daysrebel-lang: implement array subtractionMatthias Schiffer
7 daysrebel-lang: add validation and typechecking benchmarkMatthias Schiffer
7 daysrebel-lang: scope: add Context::record_type()Matthias Schiffer
Add a function for incrementally typechecking a list of statements, without actually evaluating it.
7 daysrebel-lang: typing: fix Type::ast_stmt_type() parameter nameMatthias Schiffer
7 daysrebel-lang: repl: skip output for all Unit values, not just empty statementsMatthias Schiffer
7 daysrebel-lang: scope: make Module generic againMatthias Schiffer
Even with the merged Contexts, we will need separate value and type namespaces.
7 daysrebel-lang: scope: rename Context::run() to execute()Matthias Schiffer
7 daysrebel-lang: repl: skip evaluation of empty statementsMatthias Schiffer
7 daysrebel-lang: typing: add support for typechecking body statementsMatthias Schiffer
7 daysrebel-parse: implement validation for statementsMatthias Schiffer