Ayaz Hafiz
ecab8fa25a
Make sure self-recursive checks only happen after typechecking
...
Programs like
```
after : ({} -> a), ({} -> b) -> ({} -> b)
fx = after (\{} -> {}) \{} -> if Bool.true then fx {} else {}
```
are legal because they always decay to functions, even if they may not
look like functions syntactically. Rather than using a syntactic check
to check for illegally-recursive functions, we should only perform such
checks after we know the types of values.
Closes #4291
2022-10-17 09:59:32 -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
619cd2f629
Infer ranged number for chars in patterns
2022-10-05 17:28:01 -05:00
Ayaz Hafiz
92b754f292
Illegal self recursion on toplevel defs
...
Closes #4153
2022-10-03 13:14:56 -05:00
Ayaz Hafiz
5f117be306
Improve error message when shadowing builtin type
...
Closes #3109
2022-09-30 13:40:34 -05:00
Ayaz Hafiz
01815ad23f
Ability impls that don't shadow can end up resolving to the member def
2022-09-21 12:29:06 -05:00
Ayaz Hafiz
67d0a3d36f
Symbol resolution of ability members can come from unique defs or unique shadows
2022-09-21 12:29:06 -05:00
Richard Feldman
97e2900bf5
s/rtfeldman/roc-lang/g in links to GitHub repos
2022-08-12 15:24:09 -04:00
Folkert
7c9b1897bb
fully canonicalize expect-fx
2022-08-09 14:50:24 +02:00
Folkert
bcbc8b4d50
basic canonicalization
2022-08-09 13:59:24 +02:00
Folkert
6bf3e80f51
remove some sendmap usage
2022-08-06 20:00:39 +02:00
Ayaz Hafiz
b87f09115c
Report opaques as opaques, not aliases
...
Closes #3313
Closes #3654
2022-08-01 08:02:56 -05:00
Ayaz Hafiz
10db3f8574
Detect ability specializations that overload different opaque types
2022-07-25 11:35:20 -04:00
Ayaz Hafiz
e2454f497f
Store declared implementations, both custom and derived, in abilities store
2022-07-25 09:09:01 -04:00
Ayaz Hafiz
6035e45f25
Store derivable ability members statically
2022-07-25 09:09:00 -04:00
Ayaz Hafiz
0de32ac5a9
Warn on definitions that introduce no new variables
2022-07-24 16:11:04 -04:00
Richard Feldman
b7d78d9237
Merge pull request #3598 from rtfeldman/i3558
...
Compile variables bound in multiple patterns of a branch, and detect unbound patterns
2022-07-21 16:45:52 -04:00
Ayaz Hafiz
bf8fc0d0de
Permit binding variables multiple itmes in when branches
2022-07-21 11:06:40 -04:00
Folkert
5a93da5a11
some work on expect comment regions
2022-07-21 10:42:57 -04:00
Folkert
7597d11b59
parse the region of the preceding comment for an expect
2022-07-21 10:42:57 -04:00
Folkert
b6f1fd6f40
constrain expects in the right order
2022-07-21 10:42:57 -04:00
Ayaz Hafiz
8f5580c0a5
Clippy
2022-07-19 15:04:01 -04:00
Ayaz Hafiz
7586a8a083
Check complete ability implementations during canonicalization
2022-07-19 14:30:20 -04:00
Ayaz Hafiz
37ab06b0a3
Reject implementations that don't point to abilities
2022-07-19 14:30:19 -04:00
Ayaz Hafiz
a53de2e05c
Add a comment
2022-07-19 14:30:19 -04:00
Ayaz Hafiz
e4af8af1a3
Report duplicate implementations for ability members
2022-07-19 14:30:19 -04:00
Ayaz Hafiz
666becad87
Clippy
2022-07-19 08:14:12 -04:00
Ayaz Hafiz
d2da395619
Syntactic ability links in solve
2022-07-18 18:33:28 -04:00
Ayaz Hafiz
f8cd56da41
Register specializing symbol in can opaques
2022-07-18 17:55:01 -04:00
Ayaz Hafiz
c2154ac311
Support shorthand ability implementation syntax
2022-07-18 17:55:01 -04:00
Ayaz Hafiz
96b32c36cb
Introdue ability member names before other value names
2022-07-18 17:55:01 -04:00
Ayaz Hafiz
e672ce9ebd
First pass at canonicalizing and reporting syntactic abilities
2022-07-18 17:55:01 -04:00
Ayaz Hafiz
d118e5afbc
More can abilities
2022-07-18 17:55:01 -04:00
Richard Feldman
c859ce0b23
Use Opaque over Alias
2022-07-18 17:55:00 -04:00
Ayaz Hafiz
d4d073d8c6
Rename Derived to HasAbility
2022-07-14 10:38:37 -04:00
Ayaz Hafiz
676d6b3a7f
Sorry clippy, we love long lists
2022-07-08 15:38:50 -04:00
Ayaz Hafiz
d9edb4d1bb
Support unification of recursion vars in opaques
2022-07-08 15:31:29 -04:00
Ayaz Hafiz
fc1617bf17
Phantom types
...
Closes #3314
2022-07-05 19:07:41 -04:00
Ayaz Hafiz
641bd95d04
Make sure accessor closures get the name of their assigned def, if any
2022-07-03 10:37:35 -04:00
Ayaz Hafiz
019ebd93f7
Put the capture niche in the lambda name instead of generating new names
2022-07-03 10:37:29 -04:00
Anton-4
eee85fa45d
moved all crates into seperate folder + related path fixes
2022-07-01 17:37:43 +02:00