Commit graph

867 commits

Author SHA1 Message Date
Brendan Hansknecht
37c6330c6f
cleanup when expects are run 2024-12-11 15:15:46 -08:00
Brendan Hansknecht
8068fa6d1b
still run in BinaryDev mode with roc main.roc for expect messages 2024-12-11 14:56:12 -08:00
Brendan Hansknecht
76cb2b09cd
Stop ignoring --optimize in roc --optimize main.roc
This is just inconvenient and does not make our api better.
Leads to users thinking that roc does not optimize well.
This also allows `roc dev --optimize` (which is the exact same as `roc --optimize`).
If a user wants to do that, it should be fine.

This will all eventually be replaced by the larger cli rewrite.
2024-12-10 08:51:28 -08:00
Sam Mohr
01f4d4f3da
Merge branch 'main' into cleanup_unused 2024-12-08 10:14:47 -08:00
Sam Mohr
193c23bac8
Merge pull request #7296 from smores56/proper-try-keyword
Proper `try` keyword
2024-12-05 01:38:22 -08:00
JRI98
90f517712a
Remove unused code 2024-12-05 09:18:52 +00:00
Joshua Warner
120e9be550
Move MigrationFlags from an argument on format* to a field on Buf
That has a few advantages:

* We avoid a bunch of extra parameter-passing "noise", since the vast majority of formatting code doesn't need to care about this setting beyond just passing it to nested format calls.
* It aligns really well with the "global" nature of this setting, and makes it impossible to have bugs where e.g. one callsite forgets to pass the correct value to it's children - which would lead to parts of the tree not being migrated. If this is truly a global setting on Buf, that simply can't happen.
2024-12-04 17:57:31 -08:00
Anton-4
7c1dffb777
minor improvements 2024-12-04 14:32:38 +01:00
Sam Mohr
eedade8e81
Initial working version of proper try keyword 2024-12-04 02:31:59 -08:00
Anthony Bullard
a2083cec30
Parsing support for snake_case identifiers
In this initial commit, I have done the following:

- Added unit tests to roc_parse's ident.rs file to cover at least the
  simplest Ident enum cases (Tag, OpaqueRef, and simple Access)
- Added '_' as a valid "rest" character in both uppercase and lowercase
  identifier parts
- Updated the test_syntax snapshots appropriately

There is still a lot left to do here. Such as:

- Do we want to allow multiple '_'s to parse successfully?
- Handle qualified access
- Handle accessor functions
- Handle record update functions
- Remove the UnderscoreInMiddle case from BadIdent
- Write unit tests for Malformed Idents

I am not a "Rustacean" by any means, but have been through the Book in
years past.  Any feedback on the way I wrote the tests or any other part
of the implementation would be very appreciated.
2024-12-03 20:50:47 -06:00
faldor20
f3f262574d
Check if a module is using purity inference and enable purity inference effects 2024-12-01 17:16:29 +10:00
Richard Feldman
0e550a7f68
Merge pull request #7265 from roc-lang/workspace-deps
Update cargo dependencies to use workspace
2024-11-29 17:38:03 -05:00
Luke Boswell
e43b78b354
update to workspace deps for miscellaneous 2024-11-29 11:37:39 +11:00
Luke Boswell
8ad7ecdc10
replace cargo deps with workspace in roc_build 2024-11-29 10:40:20 +11:00
Anton-4
3a1f52a55f
update to basic-cli 0.17.0 2024-11-28 20:16:07 +01:00
Anton-4
8e23f96fbd
nightly tests fixes 2024-11-19 11:41:50 +01:00
Isaac Van Doren
35f221d9de
Merge branch 'main' of https://github.com/roc-lang/roc into list-splitting 2024-11-15 21:12:51 -06:00
Isaac Van Doren
d99c347998
rename Str.split 2024-11-15 21:12:23 -06:00
Luke Boswell
0804758895
Merge pull request #6967 from jfkonecn/test-mulitple-files
Roc test can now support multiple files
2024-11-15 07:10:55 +11:00
Isaac Van Doren
f33a483502
merge main 2024-11-12 20:55:45 -06:00
Luke Boswell
29012f7d7e
Merge remote-tracking branch 'remote/main' into effectful-builtins 2024-11-13 10:39:08 +11:00
Luke Boswell
5c1eb7efe5
add a cli test that uses echo 2024-11-13 07:47:47 +11:00
Luke Boswell
4b4ab7bc0c
Merge remote-tracking branch 'remote/main' into record-suffix-warn-tweaks 2024-11-13 07:29:31 +11:00
Anton-4
9a3495cfae
minor cleanup 2024-11-12 19:16:20 +01:00
Luke Boswell
98bb9107b5
try unix instead of linux for ignore_attr 2024-11-12 09:37:04 +11:00
Luke Boswell
7295402704
try unix instead of linux for ignore_attr 2024-11-12 09:17:16 +11:00
Luke Boswell
74848bb2e5
ignore expects dev test on linux, needs further discussion 2024-11-12 09:00:37 +11:00
Luke Boswell
aad1df524f
ignore basic-cli tests on linux, broken on nix CI 2024-11-12 08:58:51 +11:00
Luke Boswell
699bea80ad try dont use both linkers on basic-cli tests 2024-11-11 21:59:59 +11:00
Luke Boswell
fb795dae14
update snapshots to use unix slashes 2024-11-11 21:42:24 +11:00
Luke Boswell
af6a7dbf54
ensure Windows git keeps line endings consitent with Unix 2024-11-11 21:27:54 +11:00
Luke Boswell
76942e4253
ignore windows tests that aren't implemented yet 2024-11-11 21:27:46 +11:00
Luke Boswell
def5372e1c fix combine_tasks_with_record_builder cli test on linux 2024-11-11 20:56:51 +11:00
Luke Boswell
fc315f7c67
revert separate test platform commits 2024-11-11 16:59:08 +11:00
Luke Boswell
e4fd9ce434
use crate for test-platform-simple-zig 2024-11-11 13:22:19 +11:00
Luke Boswell
f84aad1967
move effectful test platform into rust crate 2024-11-11 12:58:51 +11:00
Luke Boswell
e4d0115ca4
Merge remote-tracking branch 'remote/main' into rebuild-platform 2024-11-11 11:55:06 +11:00
Luke Boswell
aa98706547
complete merge remote/main into rebuild-platform 2024-11-11 11:32:46 +11:00
Luke Boswell
8a566dc339
WIP 2024-11-11 10:22:58 +11:00
Agus Zubiaga
6d0cec253d
Add List.forEachTry! builtin 2024-11-09 23:13:49 -03:00
Agus Zubiaga
644702a2b3
Add Result.onErr! builtin 2024-11-09 22:17:33 -03:00
Agus Zubiaga
12c735644f
Do not warn about pure functions in suffixed record literal fields
Records fields that allow effectful functions, should also accept
pure functions.
2024-11-09 01:05:06 -03:00
Anton-4
219ebe084a
update everything to basic-cli 0.16.0 2024-11-08 15:51:20 +01:00
Agus Zubiaga
7f8149d386
Ignore all but one cli_run effectful tests on Linux
Things go wrong when multiple tests depend on the same platform
on Linux. Tried a few workarounds but the problem persisted.
We decided to keep only one test for now.
2024-11-07 19:11:57 -03:00
Agus Zubiaga
de2260e67a
Add simple effectful cli run tests 2024-11-07 18:54:22 -03:00
Agus Zubiaga
c9f001b041
Allow ignored defs with an effectful RHS 2024-11-07 18:54:22 -03:00
Agus Zubiaga
cfc4be5254
Treat untyped suffixed functions as effectful 2024-11-07 18:54:21 -03:00
Agus Zubiaga
c1a82ae59b
Merge pull request #7199 from roc-lang/fix-imports-in-expect-7025 2024-11-06 07:56:21 -03:00
Agus Zubiaga
0dedab1725
Fix imports in expects #7025 2024-11-05 19:13:29 -03:00
Agus Zubiaga
6c505a4dc8
Add test for fixed issue 7116 2024-11-05 18:12:56 -03:00