Ayaz Hafiz
a6cf21dcf9
Revert "Lints"
...
This reverts commit f7e85b5295a44217bde9b6b83d188d84ee863d0c.
2022-10-02 21:39:48 -05:00
Ayaz Hafiz
f3689b1146
Fmt
2022-10-02 21:38:04 -05:00
Ayaz Hafiz
852fd0a127
Lints
2022-10-02 21:38:04 -05:00
Ayaz Hafiz
0cc9ea4b05
Detect and report module names that don't match what they are used as
...
Prior to this commit, if you had a module structure like
```
| - A.roc
| - Dep
| - B.roc
```
where `B.roc` was defined as
```
interface B exposes [] imports []
```
and `A.roc` was defined as
```
interface A exposes [] imports [Dep.B]
```
The compiler would hang on you. The reason is that even though we expect
`B` to be named `Dep.B` relative to `A`, that would not be enforced.
With this patch, we now enforce such naming schemes - a module must have
the namespaced name it is referenced by. Currently, we determine the
expected namespaced name by looking at how transitive dependencies of the
root module reference the module. In the future, once we have a package
ecosystem and a solid idea of "package roots", we can use the "package
root" to determine how a module should be named.
Closes #4094
2022-10-02 21:38:03 -05:00
Ayaz Hafiz
a5ebd7f477
Comments and optimizations for builtins
2022-10-02 21:38:03 -05:00
Ayaz Hafiz
5d649666fa
Detect and report module import cycles
...
Closes #3557
2022-10-02 21:38:03 -05:00
Ayaz Hafiz
c67be21636
Check that module names correspond to the paths they are defined in
...
Closes #3440
Closes #4050
2022-10-02 21:38:02 -05:00
Ayaz Hafiz
3883867b5c
Properly format characters with escape sequences
...
Ran into this just now
2022-10-02 17:10:34 -05:00
Folkert
355bbcb3a7
improve comment
2022-10-02 15:48:36 +02:00
Folkert
57e67f9878
ignore a test that does not yet work on windows
2022-10-02 15:43:39 +02:00
Folkert
675092db17
add a test for preprocessing
2022-10-02 15:41:15 +02:00
Folkert
78a5902261
on windows, run the .exe with the full path
2022-10-02 15:40:34 +02:00
Folkert
06e24fb44f
bump image size
2022-10-02 15:39:24 +02:00
Folkert
a798552dee
write valid dummy sections
2022-10-02 15:37:53 +02:00
Folkert
cf23feb996
track section alignment
2022-10-02 15:33:00 +02:00
Folkert
249901c73c
add libc functions to the linker crate, so we can run tests on windows
2022-10-02 15:29:24 +02:00
Richard Feldman
a3ee6b22af
Merge pull request #4097 from roc-lang/better-default-importing
...
Improve how builtin modules and their types are imported
2022-10-02 00:25:32 -07:00
Folkert de Vries
2b91154b93
Merge pull request #4128 from roc-lang/static-relocations
...
PE inter-section relocations
2022-10-01 00:01:56 +02:00
Ayaz Hafiz
877714e9c0
Unused imports in gen-abilities
2022-09-30 14:24:06 -05:00
Ayaz Hafiz
c97cdc0753
Fix load tests
2022-09-30 13:40:35 -05:00
Ayaz Hafiz
1cffb3376e
Ignore can errors in glue tests
2022-09-30 13:40:35 -05:00
Ayaz Hafiz
cc125d62bc
Remove redundant reference
2022-09-30 13:40:35 -05:00
Ayaz Hafiz
f745debc73
Fix scope tests
2022-09-30 13:40:34 -05:00
Ayaz Hafiz
985da70343
Add tests to ignore for now
2022-09-30 13:40:34 -05:00
Ayaz Hafiz
92aa0912ea
Report unused imports in modules
2022-09-30 13:40:34 -05:00
Ayaz Hafiz
5dc51ce444
Add unnecessary import test cases
2022-09-30 13:40:34 -05:00
Ayaz Hafiz
5f117be306
Improve error message when shadowing builtin type
...
Closes #3109
2022-09-30 13:40:34 -05:00
Ayaz Hafiz
ae122a0aea
Improve style
2022-09-30 13:40:34 -05:00
Ayaz Hafiz
c521668d4c
Simplify how builtin types are added to a module
2022-09-30 13:40:33 -05:00
Ayaz Hafiz
2028dd5b0c
Add function to get exposed types of builtin module
2022-09-30 13:40:33 -05:00
Ayaz Hafiz
6832d4054f
Better name imported
symbols to apply
or hint
symbols
2022-09-30 13:40:33 -05:00
Anton-4
efd2611911
re-enable surgical linker for cli_run tests
2022-09-30 19:35:11 +02:00
Anton-4
0aa590dfe7
Merge branch 'main' of github.com:roc-lang/roc into simplify_examples
2022-09-30 19:27:30 +02:00
Anton-4
e1277a1fc1
fixed race condition errors
2022-09-30 19:22:29 +02:00
Anton-4
81703fb3b2
Merge pull request #4131 from TimWhiting/expression_indentation_ends_prematurely_fix
...
fix expression indentation error
2022-09-30 17:16:57 +02:00
Tim Whiting
ab000a5b49
Update error text
...
fix error text
2022-09-30 07:36:24 -06:00
Jan Van Bruggen
f6c981294a
Merge pull request #4126 from roc-lang/i4064
...
Str.splitFirst should not find match if needle is longer than haystack
2022-09-29 23:30:56 -06:00
Jan Van Bruggen
cd5747a15c
Run formatter even though it makes matchesAtHelp
uglier
...
Signed-off-by: Jan Van Bruggen <JanCVanB@pm.me>
2022-09-29 23:28:34 -06:00
Jan Van Bruggen
5d814b3ea5
Refactor matchesAtHelp
for clarity
...
Signed-off-by: Jan Van Bruggen <JanCVanB@pm.me>
2022-09-29 23:28:27 -06:00
Ayaz Hafiz
c9c2f61e3e
Add some docs to matchesAtHelp
2022-09-29 22:32:16 -05:00
Folkert
28eb6cc498
remove absolute again; this test does not actually test it
2022-09-29 21:37:35 +02:00
Tim Whiting
f323fe6534
fix expression indentation error
2022-09-28 20:11:24 -06:00
Folkert
1a7025b20c
clippy things
2022-09-29 00:27:28 +02:00
Brian Carroll
4f23bc39f0
Merge pull request #3552 from roc-lang/csv_decoding-server_example
...
CSV Decoding in pure Roc
2022-09-28 21:46:26 +01:00
Folkert
1254c9f8db
clippy
2022-09-28 20:39:16 +02:00
Folkert
4780144e38
simplify PE tests
2022-09-28 20:36:00 +02:00
Folkert
ba704d731f
do inter-app relocations (PE)
2022-09-28 20:35:27 +02:00
Ayaz Hafiz
1d7dc65800
Str.splitFirst should not find match if needle is longer than haystack
...
Closes #4064
2022-09-28 13:14:36 -05:00
Anton-4
eaacb86ad9
Merge branch 'main' of github.com:roc-lang/roc into simplify_examples
2022-09-28 19:48:46 +02:00
Folkert de Vries
190ff7e21a
Merge pull request #4122 from roc-lang/dependabot/cargo/env_logger-0.9.1
...
Bump env_logger from 0.9.0 to 0.9.1
2022-09-28 16:54:47 +02:00