Commit Graph

126 Commits

Author SHA1 Message Date
Ayaz Hafiz
c9953129cb
Remove problem storage in Type::Erroneous 2022-11-08 14:11:24 -06:00
Ayaz
b984351514
Merge pull request #4489 from roc-lang/types-soa-more-in-solve
Types SoA for aliases instantiated during solving
2022-11-08 14:06:57 -06:00
Folkert de Vries
95f8bac859
Merge pull request #4485 from roc-lang/types-soa
Types SoA and Type -> Variable conversion via SoA
2022-11-08 20:32:27 +01:00
Ayaz Hafiz
7034a4d692
Types SoA for aliases instantiated during solving 2022-11-08 12:57:30 -06:00
Ayaz Hafiz
b0bcda4117
typo 2022-11-08 09:00:25 -06:00
Ayaz Hafiz
db8e135a05
Simplify AbilitySet storage 2022-11-08 09:00:25 -06:00
Ayaz Hafiz
b7af241538
Address clippy for Types 2022-11-08 09:00:25 -06:00
Ayaz Hafiz
e240b18b27
Recover Erroneous in type 2022-11-08 09:00:25 -06:00
Ayaz Hafiz
58020a55d6
Type to variable through Types SoA 2022-11-08 09:00:24 -06:00
Ayaz Hafiz
5da11d7fdd
Index into Types 2022-11-08 09:00:24 -06:00
Ayaz Hafiz
dad9a8e537
Pass Types SoA repr in types to Variable translation 2022-11-08 09:00:24 -06:00
Folkert
93b9130edf
Type soa and conversion from existing data structure 2022-11-08 09:00:24 -06:00
Luke Boswell
2c2a70b8e7 Merge remote-tracking branch 'upstream/main' into rust-docs 2022-11-06 09:15:57 +11:00
Folkert
134de80150
various updates 2022-11-03 17:18:27 +01:00
Folkert
66a1ba00eb
1.65 clippy fixes 2022-11-03 16:20:37 +01:00
Luke Boswell
f3bdb5f321
updating rust package documentation 2022-11-03 20:00:06 +11:00
Ayaz Hafiz
9ab5d0efb8
Constraining of list patterns 2022-10-31 17:05:08 -05:00
Ayaz Hafiz
b0a8b85de3
Canonicalization of list patterns 2022-10-31 17:04:47 -05:00
Ayaz Hafiz
a526fd92aa
inferred extension vars are material if they're not flex or empty 2022-10-31 09:38:22 -05:00
Ayaz Hafiz
4f367e2608
Clippers lose to the Thunder, I lose to Clippy 2022-10-31 09:38:22 -05:00
Ayaz Hafiz
9854f5f2ac
Print alias's underlying structures if OIOP vars are material 2022-10-31 09:38:22 -05:00
Ayaz Hafiz
debe6332c5
Support OIOP for type aliases 2022-10-31 09:38:21 -05:00
Ayaz Hafiz
85e58440de
Allow too many args 2022-10-31 09:37:41 -05:00
Ayaz Hafiz
4d48ea7c2f
Materialize extension variable polarity in error type reporting 2022-10-31 09:37:40 -05:00
Ayaz Hafiz
3c15ff4694
Correctly print wildcards as appropriate in error messages 2022-10-31 09:37:39 -05:00
Ayaz Hafiz
d77080529a
Introduce polarity for extension variable printing 2022-10-31 09:37:39 -05:00
Ayaz Hafiz
0da72df5e9
Add ability slice to eq obligation checker 2022-10-24 14:00:46 -05:00
Ayaz Hafiz
46b741e9dd
Correctly clone able vars across subs 2022-10-24 13:59:52 -05:00
Ayaz Hafiz
49e19d96e5
Print multiple abilities in error types 2022-10-24 13:59:52 -05:00
Ayaz Hafiz
94fc58a508
Pretty-print variables bound to multiple abilities 2022-10-24 13:59:52 -05:00
Ayaz Hafiz
1e6181d2cb
New data structure for storing sorted abilities bound to a variable 2022-10-24 13:59:51 -05:00
Ayaz Hafiz
229548571b
Represent "able" variables with slices of abilities 2022-10-24 13:59:51 -05:00
Ayaz Hafiz
0f0678ce73
s/closure_names/symbol_names/g in subs 2022-10-24 13:59:51 -05:00
Ayaz Hafiz
6bb97c92b9
Canonicalize multiple abilities bound to a type variable 2022-10-24 13:56:07 -05:00
Ayaz
89f14e73a0
Merge pull request #4358 from roc-lang/derive-opaque-defs
Auto-derive ability implementations for opaques in canonicalization
2022-10-24 13:24:51 -05:00
Ayaz Hafiz
5164994fb5
Do not attempt to lookup functions in expects
Functions are not useful to print in expect results, because they are
only printed opaquely as `<function>`. Moreover, their transformation to
closure sets during mono can be extremely lossy, up to and including the
elision of symbols for function closure symbols. As such, simply do not
attempt to lookup or print functions referenced in expects.

Closes #4389
2022-10-24 10:28:56 -05:00
Ayaz Hafiz
e75f3c3c79
Get rid of MemberImpl::Derived
We don't need this anymore, since derived members become Impls during
canonicalization now!
2022-10-23 20:48:07 -05:00
Ayaz Hafiz
05e8e6de6f
Disallow typing optional fields when required fields are annotated
Closes #4313
2022-10-18 15:50:20 -05:00
Ayaz Hafiz
20e4295eea
Make sure type variables bound to abilities are instantiated in aliases
Closes #4259
2022-10-14 13:56:00 -05:00
Ayaz Hafiz
a9c79db5db
Allow complicated type 2022-10-11 10:49:24 -05:00
Ayaz Hafiz
7e79ff55f1
Serialize abilities store and solved implementations with subs 2022-10-11 10:31:21 -05:00
Ayaz Hafiz
46aab8ad8c
Use roc_serialize for subs serialization 2022-10-11 09:19:25 -05:00
Ayaz Hafiz
781d1a2642
Serialize uls_of_var in subs cache 2022-10-10 16:42:04 -05:00
Ayaz
51c687df54
Merge branch 'main' into i4150
Signed-off-by: Ayaz <20735482+ayazhafiz@users.noreply.github.com>
2022-10-08 16:08:35 -05:00
Ayaz Hafiz
178b634266
Treat single quote literals as ranged numbers for inference purposes 2022-10-05 17:28:00 -05:00
Ayaz Hafiz
16f43f5768
Clippy 2022-10-05 17:25:12 -05:00
Ayaz Hafiz
61cf8e53e6
Have FunctionOrTagUnion include multiple possible tags 2022-10-05 17:24:52 -05:00
Ayaz Hafiz
e9efc95425
Obligation checking for the Hash ability
This implements type-level checks that types can and cannot implement
the `Hash` ability.

Part of #4195
2022-10-04 10:51:14 -05:00
kilianv
6dbebd7834
Update Bool to be opaque 2022-09-20 14:42:01 -05:00
Ayaz Hafiz
041b91e031
Add more test cases 2022-09-19 10:45:31 -05:00