Richard Feldman
fd40fed937
Fix a bunch of errors from clippy --tests
2022-05-10 15:21:48 -04:00
Richard Feldman
531d254bca
Fix parser tests
...
Regions changed in 15187024233795c059342adc3c23b8a148a7f26e
2022-05-06 12:10:08 -04:00
Richard Feldman
dcea38dcf6
Add parse test for tui-platform/Package-Config.roc
2022-05-06 12:06:28 -04:00
Richard Feldman
8273775540
Improve test_parse error message
2022-05-06 12:06:28 -04:00
ayazhafiz
514af619f5
Store region of type annotation correctly
2022-05-06 12:06:27 -04:00
Richard Feldman
893bd4f7ab
Improve error message in test_parse
2022-04-25 17:04:34 -04:00
Richard Feldman
85e7969c2d
Replace references to "global tag" with "tag"
2022-04-25 17:04:34 -04:00
Ayaz Hafiz
ce407168a9
Update opaque parse tests
2022-04-25 13:59:57 -04:00
Ayaz Hafiz
f1dc9c8298
Opaques take @ : %s/\$\([A-Z]\)/@\1/g
2022-04-25 12:26:38 -04:00
Ayaz Hafiz
2ab01107d3
Removing extra private tag references
2022-04-25 11:43:55 -04:00
Ayaz Hafiz
1ed9cf551a
Remove private tags from Ast
2022-04-25 11:20:37 -04:00
Ayaz Hafiz
67eb4b9faa
Remove private tags from idents
2022-04-25 11:13:30 -04:00
Richard Feldman
6e642a6fca
fix typo
2022-04-24 13:22:41 -04:00
Joshua Warner
b1e3913041
Allow parsing if
as part of the right-hand-side of a binary expression
2022-04-24 09:56:53 -07:00
Richard Feldman
122a1d57a0
Merge remote-tracking branch 'origin/trunk' into sqrt-unchecked
2022-04-23 15:40:30 -04:00
Ayaz
5188f8f7df
Merge branch 'trunk' into i/2878
2022-04-18 21:46:23 -04:00
Kevin Gillette
cd8ab753e3
remove %% operator
2022-04-18 19:15:14 -06:00
Ayaz Hafiz
f129777115
Explicitly disallow ability definitions in nested scopes
...
Abilities can only be defined on the toplevel of a module. There is a
technical reason to this, which is that during type solving we must
introduce all abilities at the very beginning, and we need to make sure
ranks are correct. But there is a practical reason as well, which is
that nested ability definitions don't seem to be very useful.
Note that specializations can be nested, and are allowed to be. Also, we
can revisit this in the future. I just don't want experiments to break
right now because someone uses an ability in a nested scope where we
don't expect.
Closes #2878
2022-04-18 18:04:46 -04:00
Folkert
e112f6ad2c
Merge remote-tracking branch 'origin/trunk' into builtins-in-roc
2022-04-16 21:01:51 +02:00
Ayaz
5652e72f99
Missing test
2022-04-14 12:50:28 -04:00
Ayaz Hafiz
233ea23979
Revert "Detect outdents too far"
...
This reverts commit 1c2ca2e3f5ae12d114cc72970035caf937d6e413.
2022-04-14 10:47:20 -04:00
Ayaz Hafiz
dc2d9ceeac
Detect outdents too far
2022-04-14 10:47:20 -04:00
Ayaz Hafiz
362ca1d914
Fix parse tests
2022-04-14 10:47:18 -04:00
Ayaz Hafiz
0c21821b04
Make sure outdented records parse
2022-04-14 09:31:55 -04:00
Ayaz Hafiz
3c03b7004c
Test for outdented list parse
2022-04-14 09:31:26 -04:00
Folkert
6ef443d1b0
Merge remote-tracking branch 'origin/trunk' into builtins-in-roc
2022-04-10 19:14:00 +02:00
Folkert
1d0f9e9192
Merge remote-tracking branch 'origin/trunk' into builtins-in-roc
2022-04-08 15:47:11 +02:00
Ayaz Hafiz
1edbe32252
Fix parse tests
2022-04-07 17:22:05 -04:00
Ayaz Hafiz
66ec1b4a84
Basic canonicalization and error checking for abilities
2022-04-07 17:21:17 -04:00
Ayaz Hafiz
a3ac68a41f
Split up Defs into TypeDef and ValueDef
...
Just a refactoring PR. This is useful because during canonicalization
we always process type defs first, then value defs. With abilities this
distinction continues to grow; in that case, we have patterns associated
with types that we want to process before patterns from values.
2022-04-06 22:18:57 -04:00
Ayaz Hafiz
bd8333ebb1
Parse multiple abilities behind each other
2022-04-06 11:20:51 -04:00
Ayaz Hafiz
2dc0445f46
s/AbilityDemand/AbilityMember
...
This is a better name
2022-04-06 11:20:34 -04:00
Folkert
4e1197165b
Merge remote-tracking branch 'origin/trunk' into builtins-in-roc-delayed-alias
2022-03-18 21:25:52 +01:00
ayazhafiz
84c7c49110
Fix parse error
2022-03-12 23:55:33 -06:00
hafiz
7de55076b5
Update compiler/parse/src/type_annotation.rs
...
Co-authored-by: Richard Feldman <oss@rtfeldman.com>
2022-03-12 23:23:09 -06:00
Richard Feldman
da64cc0a1d
cargo fmt
2022-03-12 23:43:45 -05:00
ayazhafiz
d92a5b9424
Reporting for abilities parsing
2022-03-12 22:08:01 -06:00
ayazhafiz
d7abc3897b
Parse abilities
2022-03-12 21:29:06 -06:00
Folkert
831a90e310
Merge remote-tracking branch 'origin/trunk' into builtins-in-roc
2022-03-08 22:36:06 +01:00
Jan Van Bruggen
99c825aa99
Simplify example platform names
2022-03-07 19:59:29 -07:00
Folkert
adf4ad22a5
Merge remote-tracking branch 'origin/trunk' into builtins-in-roc
2022-03-05 20:55:15 +01:00
Richard Feldman
887a07b455
Merge pull request #2596 from rtfeldman/joshuawarner32/listclosing-braces
...
Allow closing braces in collections to be at any indent level
2022-02-28 20:00:44 -05:00
Folkert
bd31503855
Merge remote-tracking branch 'origin/trunk' into builtins-in-roc
2022-02-28 18:55:20 +01:00
Richard Feldman
d3acf34415
Merge pull request #1591 from rtfeldman/single-quote-literal
...
Single Quote literal
2022-02-26 23:27:46 -05:00
Joshua Warner
611d1784a9
Add tests
2022-02-26 14:15:46 -08:00
Joshua Warner
ab563fc9a5
Remove dead code
2022-02-26 13:34:53 -08:00
Joshua Warner
b2bb9dcd65
improve parser snapshot test error messages
2022-02-26 13:34:53 -08:00
Joshua Warner
333234aad9
Improve error message for no_extra_snapshot_test_files test
2022-02-26 13:32:20 -08:00
Joshua Warner
0e3b9e5624
Allow incorrect indents for closing braces, to be fixed in the formatter
2022-02-26 13:31:45 -08:00
Joshua Warner
2682193b76
Fix compile error with --features=parse_debug_trace
2022-02-26 13:31:08 -08:00