J.Teeuwissen
87abe8df7d
Merge branch 'resetref' into Frame-Limited
2023-04-03 10:02:31 +02:00
J.Teeuwissen
018e142997
merge remainders
2023-03-31 21:11:13 +02:00
J.Teeuwissen
7759ce6fc4
Merge branch 'main' into Frame-Limited
2023-03-31 20:46:39 +02:00
J.Teeuwissen
9b410694fe
Merge branch 'main' into Frame-Limited
2023-03-30 20:38:05 +02:00
Folkert
09779f65ad
add NullPointer to mono::ir::Expr
2023-03-30 20:18:04 +02:00
J.Teeuwissen
d4ed6f7778
start resetref
2023-03-29 11:57:13 +02:00
Ayaz Hafiz
2a9e0583bc
Remove inaccurate debug assertion in IR gen
...
There might be more symbols than field layouts when restructuring a
record if the record is a newtype.
Closes #4759
2023-03-28 15:06:44 -05:00
Ayaz Hafiz
3f532df981
Generate code for recursive nullable wrapped lambda sets
2023-03-27 10:11:49 -05:00
Ayaz
eadbb4eddd
Merge pull request #5202 from roc-lang/i5176
...
Compilation of when expressions with redundant branches and guards
2023-03-25 20:02:22 -05:00
Ayaz
8c55e8126d
Merge pull request #5203 from roc-lang/virtual-dom-annotations
...
Fix a few bugs Virtual-DOM cropped up
2023-03-25 20:00:51 -05:00
Ayaz Hafiz
f75248d206
Factor out mono literal and pattern into smaller crates
2023-03-25 16:33:55 -05:00
Ayaz Hafiz
570876129b
Format
2023-03-25 16:14:31 -05:00
Ayaz Hafiz
dd55be6142
Handle guards that appear multiple times in a compiled decision tree
...
Suppose we have a when expression
```
15 if foo -> <b1>
b if bar -> <b2>
_ -> <b3>
```
that may have a decision tree like
```
15?
\true => foo?
\true => <b1>
\false => bar?
\true => <b2>
\false => <b3>
\false => bar?
\true => <b2>
\false => <b3>
```
In this case, the guard "bar?" appears twice in the compiled decision
tree. We need to materialize the guard expression in both locations in
the compiled tree, which means we cannot as-is stamp a compiled `bar?`
twice in each location. The reason is that
- the compiled joinpoint for each `bar?` guard needs to have a unique ID
- the guard expression might have call which needs unique call spec IDs,
or other joins that need unique joinpoint IDs.
So, save the expression as we build up the decision tree and materialize
the guard each time we need it. In practice the guards should be quite
small, so duplicating should be fine. We could avoid duplication, but
it's not clear to me how to do that exactly since the branches after the
guard might end up being different.
2023-03-25 16:14:21 -05:00
Ayaz Hafiz
393250db92
Utility to collect symbols bound by a pattern
2023-03-25 16:14:21 -05:00
Ayaz Hafiz
fe9be63787
Utility to substitute many symbols at once
2023-03-25 16:14:20 -05:00
Ayaz Hafiz
f3d1582a5e
More debugging for missing lambda sets
2023-03-25 15:01:41 -05:00
J.Teeuwissen
ca767bf385
matching closure_arguments
2023-03-23 10:59:46 +01:00
Ayaz Hafiz
e6094df69b
Fast-path for determining ability member impls for builtin opaques
2023-03-22 17:08:41 -05:00
Folkert
fe15a2e79c
Merge remote-tracking branch 'origin/main' into glue-getters-rtfeldman
2023-03-08 19:46:00 +01:00
Ayaz Hafiz
739bdfe64e
Fix a bug in chasing assigned/hole on switch
2023-03-05 22:19:16 -06:00
Ayaz Hafiz
7914b07a2f
Eliminate unneeded joinpoints in union lambda dispatches
2023-03-05 22:10:42 -06:00
Ayaz Hafiz
a2389c7652
Eliminate joinpoints in trivial lambda set switches
2023-03-05 21:59:01 -06:00
Ayaz Hafiz
9166922e39
Remove unused is_terminal
2023-03-05 21:41:50 -06:00
Folkert
853c0387dc
cleanup
2023-03-05 17:33:48 +01:00
Folkert
769a4c415b
update remaining cli tests
2023-03-05 16:57:51 +01:00
Folkert
180187e5af
get old examples to work
2023-03-01 21:56:14 +01:00
Folkert
1bf2cc3b8c
cleanup
2023-02-25 16:23:40 +01:00
Folkert
35980e50b8
fix function getters
2023-02-25 15:47:20 +01:00
Folkert
033618f3f4
fixes to get rocLovesRust to work
2023-02-22 21:17:50 +01:00
Folkert
0d4135c57a
Merge remote-tracking branch 'origin/main' into glue-getters-rtfeldman
2023-02-22 21:11:39 +01:00
Folkert de Vries
bd6623dab4
Merge pull request #5055 from roc-lang/abilities-bug-generic
...
Lambda set compaction must preserve unique specializations of concrete types
2023-02-21 15:24:23 +01:00
Folkert de Vries
088bd5211f
Merge pull request #5054 from roc-lang/glue-generate-lambda-set-callers
...
Glue generate lambda set callers
2023-02-21 02:19:53 +01:00
Ayaz Hafiz
e5c3376e90
Debug ProcLayouts
2023-02-20 18:49:18 -06:00
Ayaz
2f251310c0
Merge pull request #5010 from roc-lang/tuple-record-unify
...
Unify IR generation for tuples and records
2023-02-20 18:40:52 -06:00
Folkert
958d44a21c
cleanup
2023-02-20 22:25:48 +01:00
Folkert
68524ef07e
generate callers based on layout traversal
2023-02-20 22:05:35 +01:00
Folkert
90c45a197b
use extracted functions
2023-02-18 17:57:50 +01:00
Folkert
784ebde24b
helper functions
2023-02-18 17:34:41 +01:00
Folkert
edd10a079c
create hook for future glue proc codegen
2023-02-18 17:34:23 +01:00
Folkert
b6bae82913
hello world works
2023-02-14 22:11:23 +01:00
Ayaz Hafiz
2903ec4ac2
Remove obsolete comments
2023-02-13 10:54:05 -06:00
Folkert
6c15284a8f
more wip; now we just need to generate the exposed procs at the right time
2023-02-08 22:56:38 +01:00
Ayaz Hafiz
a22dcb5784
Unify record and tuple access
2023-02-08 11:13:36 -05:00
Ayaz Hafiz
1ee5f9d02b
Unify logic for building record and tuple IR
2023-02-08 11:03:02 -05:00
Joshua Warner
5a6be05ead
implement mono / lowering for tuples
2023-02-07 18:54:50 -08:00
Ayaz Hafiz
1e22a2bbcd
Layout-cache variable invalidation must compare by root keys
...
After unification, variable roots can change. So, when we invalidate
entries in the layout cache, we must compare for variable equivalence
relative to the current state of subs.
2023-01-30 13:06:44 -06:00
J.Teeuwissen
957f44966c
start perceus reference count
2023-01-26 17:13:29 +01:00
Ayaz Hafiz
741b1a1bd5
Always show one level of unions when printing layouts
2023-01-25 15:16:06 -06:00
Ayaz Hafiz
3382be6cb9
Chase recursive layouts as appropriate
2023-01-25 15:10:56 -06:00
Folkert
3417a0e059
fix silent merge request wrt record accessors
2023-01-25 00:02:19 +01:00