Commit graph

299 commits

Author SHA1 Message Date
snobee
4f7729c044
Merge remote-tracking branch 'upstream' into annotate-type-signatures 2025-01-27 14:21:24 -08:00
snobee
46736ccaea
Handle errors in generated type annotations 2025-01-27 13:50:53 -08:00
Sam Mohr
3a6c622727
Fix failing tests, remove unnecessary NONE bitflag 2025-01-19 15:33:01 -08:00
Ayaz Hafiz
a0461679dd Restrict usages of type variables in non-generalized contexts
Type variables can only be used on functions (and in number literals as
a carve-out for now). In all other cases, a type variable takes on a
single, concrete type based on later usages. This check emits errors
when this is violated.

The implementation is to check the rank of a variable after it could be
generalized. If the variable is not generalized but annotated as a type
variable, emit an error.
2025-01-02 14:26:37 -06:00
Sam Mohr
eedade8e81
Initial working version of proper try keyword 2024-12-04 02:31:59 -08:00
Luke Boswell
624021bf49
replace cargo deps with workspace in test_solve_helpers, test_syntax, types, uitest, unify, work, worker 2024-11-29 11:31:48 +11:00
Agus Zubiaga
0a98580277
Use "opaques" instead of "opaque types" in reporting 2024-11-25 19:32:08 -03:00
Agus Zubiaga
2e96aca0fd
Merge branch 'main' into specialize-exprs 2024-11-23 01:48:51 -03:00
Richard Feldman
ed6ad1bc82
Get a failing specialize_expr test 2024-11-08 00:55:04 -05:00
Agus Zubiaga
cfc4be5254
Treat untyped suffixed functions as effectful 2024-11-07 18:54:21 -03:00
Agus Zubiaga
89a918cebe
Fix unifying pure with flex vars 2024-11-07 18:54:19 -03:00
Agus Zubiaga
6533e9084d
Add fx to ErrorType 2024-11-07 18:54:19 -03:00
Agus Zubiaga
9a5a5c3462
Remove irrelevant todos 2024-11-07 18:54:18 -03:00
Agus Zubiaga
6adc6d9168
Report ignored statement results 2024-11-07 18:54:18 -03:00
Agus Zubiaga
b01771c5ae
Show effectful function name in mismatches 2024-11-07 18:54:18 -03:00
Agus Zubiaga
f666dba67d
Report effectful top-level exprs 2024-11-07 18:54:17 -03:00
Agus Zubiaga
6e6382ab23
Canonicalize and constrain statement expr in purity inference mode 2024-11-07 18:54:15 -03:00
Agus Zubiaga
7af05cc6c9
Constrain function annotation fx to body 2024-11-07 18:54:13 -03:00
Agus Zubiaga
b9b85a222f
Do not use const fx vars when canonicalizing annotations 2024-11-07 18:54:13 -03:00
Agus Zubiaga
7776883262
Unify functions fx vars 2024-11-07 18:54:13 -03:00
Agus Zubiaga
5a5abe3bc5
Unify call's fx var with that of the enclosing function 2024-11-07 18:54:12 -03:00
Agus Zubiaga
3cef756559
Add fx var to Type::Function et al 2024-11-07 18:54:12 -03:00
Agus Zubiaga
386a5055ee
Add effect_type to can ClosureData 2024-11-07 18:54:11 -03:00
Sam Mohr
39687fdb97
Merge branch 'main' into return-keyword 2024-10-26 06:50:16 -07:00
Ayaz
e1183e58e5
Merge pull request #7179 from JRI98/unused_emptytuple
Remove unused EmptyTuple variant from FlatType enum
2024-10-25 09:19:57 -04:00
Sam Mohr
294f0c0d1f
Merge branch 'main' into return-keyword 2024-10-24 23:01:10 -07:00
JRI98
edd0bb553d
Remove unused EmptyTuple variant from FlatType enum 2024-10-22 16:29:53 +01:00
Richard Feldman
8997c80573
Remove deprecated roc_collections::soa things 2024-10-21 23:17:20 -04:00
Richard Feldman
08b32927f1
Implement @smores56's feedback from #7156 2024-10-21 22:10:44 -04:00
Richard Feldman
62b4fe6943
clippy 2024-10-21 22:10:43 -04:00
Richard Feldman
e589923ae8
Make collections::soa use the soa crate 2024-10-21 22:10:43 -04:00
Richard Feldman
44d00e1f13
Updates for making soa no_std 2024-10-21 22:10:43 -04:00
Richard Feldman
49d1786f6c
Remove more push_new and extend_new usages 2024-10-21 22:10:43 -04:00
Richard Feldman
b2ea0b842c
Revert "Do some checked SoA stuff"
This reverts commit c79d7745f6eb345fd50a7cb4a2a7dd6fb6f8f1fc.
2024-10-21 22:10:43 -04:00
Richard Feldman
a8d3280b02
Do some checked SoA stuff 2024-10-21 22:10:42 -04:00
Sam Mohr
7518a2c5ab
Address PR comments, add syntax tests 2024-10-21 03:06:43 -07:00
Sam Mohr
b3e60f9d3a
Implement return keyword 2024-10-20 08:58:59 -07:00
Richard Feldman
2567c8b545
Convert over Subs to use the new soa crate 2024-10-10 00:30:35 -04:00
Richard Feldman
586959780b
Revert "Try out converting subs to use soa stuff directly"
This reverts commit 4a7d7e42d6.
2024-10-10 00:06:25 -04:00
Richard Feldman
4a7d7e42d6
Try out converting subs to use soa stuff directly 2024-10-10 00:06:22 -04:00
Richard Feldman
be0f1223eb
Update soa 2024-10-10 00:05:55 -04:00
Richard Feldman
1f9e47e68c
Fix a bunch of monomorphization stuff 2024-09-27 21:09:56 -04:00
Richard Feldman
87b7bb1fac
Fix "opaquees" in error message 2024-09-25 22:11:14 -04:00
Agus Zubiaga
762799052e
Merge branch 'main' into typecheck-module-params 2024-08-07 18:55:33 -03:00
Agus Zubiaga
d23a8dc618
Fix importing of module params vars 2024-07-02 22:48:47 -03:00
Agus Zubiaga
5ec4b042bb
Constrain and solve import params
No reporting yet
2024-07-02 04:10:46 -03:00
Anton-4
05a61e2210
clippy + fmt 2024-06-19 12:34:10 +02:00
Anton-4
5c45cc9c3e
fmt 2024-04-15 19:38:04 +02:00
Anton-4
dc96e194bd
clippy 2024-04-15 19:36:52 +02:00
Richard Feldman
204cee7d60
Clean up more unused Nat stuff 2024-01-26 16:23:21 -05:00