Sam Mohr
de124ecc3e
Finish adding tests
2024-11-02 21:58:25 -07:00
Sam Mohr
2da08be8ef
Remove old record builder syntax
2024-09-21 04:44:44 -07:00
snobee
6edee521cb
add tests
2024-09-06 19:34:11 -07:00
Sam Mohr
12df3a04de
Merge attempt
2024-08-19 23:34:05 -07:00
Sam Mohr
7e72541a79
Merge branch 'main' into builtin-task
2024-08-12 23:12:38 -07:00
Joshua Warner
d25c048d48
Move Full from fmt to parse and reorganize confusingly-named Module ast type
2024-08-07 23:01:49 -07:00
Sam Mohr
8288af3156
Merge branch 'main' into builtin-task
2024-07-31 13:36:32 -07:00
Aidan
2529fa0721
get rid of extra newlines
2024-07-29 11:10:16 -04:00
Aidan
125990855f
Merge branch 'main' into store-all-space-between-annotation-body
2024-07-29 09:46:05 -04:00
Luke Boswell
eca453d07f
Merge remote-tracking branch 'remote/main' into builtin-task
2024-07-29 16:05:51 +10:00
Joshua Warner
ecb8b12167
Add back working tests
2024-07-27 14:49:56 -07:00
Aidan
2738cd717d
cargo fmt
2024-07-27 17:37:28 -04:00
Aidan
4e4d9b0d4c
add tests
2024-07-27 17:18:58 -04:00
Aidan
7fe052322c
update test, fix logic
2024-07-27 16:55:13 -04:00
Joshua Warner
4f32f43048
Implement block / indent based parsing
...
... and enforce that defs can only occur in blocks (or, inside parenthesized expressions)
2024-07-27 13:34:16 -07:00
Aidan
db1c230f1f
add test
2024-07-27 12:50:48 -04:00
Luke Boswell
b489c44b19
Merge remote-tracking branch 'remote/main' into builtin-task
2024-07-19 19:51:50 +10:00
Sam Mohr
618b713ecd
Merge branch 'main' into new-builder-syntax
2024-07-07 18:33:36 -07:00
Sam Mohr
f415017c90
Implement new builder syntax alongside old one
2024-07-07 03:28:59 -07:00
JRI98
25084b18ec
Fix handling of spaces after for as
2024-07-05 09:40:56 +01:00
Sam Mohr
700c7ae9aa
Add Task as a built-in module/type
2024-06-25 00:03:56 -07:00
Evan Relf
2a71dccf5e
Add tests
2024-06-19 15:19:25 -07:00
Agus Zubiaga
e3b600c282
New package
header syntax
...
Implements the new package header syntax as discussed in Zulip [1].
package [Csv] {
parser: "../parser/main.roc"
}
Old headers still parse and are automatically upgraded to the new
syntax by the formatter.
[1] 418444862
2024-05-01 10:49:03 -03:00
Agus Zubiaga
8dedd9f03c
New app
header syntax
...
Implements the new app header syntax as discussed in Zulip [1].
app [main] {
cli: platform "../platform/main.roc",
json: "../json/main.roc"
}
Old headers still parse and are automatically upgraded to the new
syntax by the formatter.
[1] 418444862
2024-05-01 10:49:01 -03:00
Agus Zubiaga
057a18573a
New module
header
...
Implements the new `module` header syntax as described in "module and package changes" [1]:
```
module [Request, Response, req]
```
The old syntax should still work fine, and is automatically upgraded to the new one
when running `roc format`.
[1] https://docs.google.com/document/d/1E_77fO-44BtoBtXoVeWyGh1xN2KRTWTu8q6i25RNNx0/edit
2024-05-01 10:39:12 -03:00
Agus Zubiaga
7ebfc6d06d
Support both inline and header imports
...
Load will now convert header imports to inline import defs, so that
we can support both temporarily.
2024-04-20 19:04:09 -03:00
Luke Boswell
f9771a9983
split test_utils
2024-04-15 20:30:34 +10:00
Richard Feldman
02bc54292f
Update fmt tests to not use Nat
2024-01-26 16:17:06 -05:00
Anton-4
1126f85b5a
fix clippy unnecessary hashes
2024-01-01 16:38:36 +01:00
JRI98
0599066865
Fix format for the 'as' keyword
2023-12-07 10:46:58 +00:00
Richard Feldman
315d185b2b
Fix test
2023-08-10 21:17:16 -04:00
Richard Feldman
2da41be29f
Merge remote-tracking branch 'origin/main' into abilities-syntax
2023-08-10 20:36:01 -04:00
Folkert
ef39bad7c6
auto clippy fixes
2023-07-10 18:27:08 +02:00
Kiryl Dziamura
1bb3c3d1dd
Make has
have 4 identation spaces
2023-07-04 11:24:40 +02:00
Bryce Miller
cb08225bf0
|
-> where
2023-06-05 20:19:00 -04:00
Bryce Miller
76551375b9
has -> implements in fn names
2023-05-26 23:25:21 -04:00
Bryce Miller
91e37293a2
abilities syntax has
-> implements
2023-05-24 21:29:38 -04:00
Agustin Zubiaga
4cd2c957ca
Format multiline reecord builder fields nicely
2023-05-17 12:48:37 -03:00
Agustin Zubiaga
5edcb31f32
Outdentable record builders
2023-05-17 12:21:39 -03:00
Agustin Zubiaga
d1feb00170
Track spaces between : and <- in record builders
2023-05-17 11:49:06 -03:00
Agustin Zubiaga
731cd4257d
Record Builder colon arrow syntax
2023-05-16 22:44:55 -03:00
Agustin Zubiaga
6670fbb1ab
Multiple record builder error
2023-05-08 19:26:47 -03:00
Agustin Zubiaga
71c80171d4
Add record builder apply fmt test
2023-05-07 15:56:44 -03:00
Agustin Zubiaga
c2e50a22b6
Record Builder formatting
2023-05-07 15:51:08 -03:00
Luca Cervello
a4410fe052
fix: add spaces around ? in optional record field
2023-02-08 18:41:22 +01:00
Joshua Warner
0b8e68f70d
Fix approximately a bajillion fmt and parsing bugs
...
(discovered by fuzzing)
There's more to come, but this seems like a good batch for now.
2023-01-13 18:20:44 -08:00
Joshua Warner
bfeddc470a
Move syntax tests to a dedicated crate
...
* test_fmt moves out of fmt crate
* test_parse _mostly_ moves out of parse crate and into `test_snapshots.rs` (some simple tests remain)
* now there's only two fuzz targets, fuzz_expr and fuzz_module, that cover both parsing and formatting
* added a system to auto-add new snapshot entries for new test files
* took some commented-out tests in `test_parse` and converted them to snapshot tests
* moved test_fmt's verification of formatting consistency into test_snapshots
* fixed a huge derp on my part where the fmt fuzzer in #4758 was completely useless (broken by refactoring just prior to submitting the PR)
* fixed a formatting bug found by fuzzing (bound_variable.expr.roc) - that I missed earlier due to ^^^ that derp
* no longer have roc_test_utils as a dependency in fmt - which was causing problems for the wasm build
2022-12-26 22:50:24 -08:00