Commit graph

13739 commits

Author SHA1 Message Date
Richard Feldman
ea5365d6cc
Make Newlines optimize better to bool 2022-01-30 20:40:50 -05:00
Richard Feldman
5c6d2a909e
Make Collection formattable 2022-01-30 20:40:50 -05:00
Richard Feldman
2eb9243942
Add parse tests for hosted modules 2022-01-30 20:40:50 -05:00
Richard Feldman
02263dbf42
Report hosted module parse errors 2022-01-30 20:40:50 -05:00
Richard Feldman
121e387f5a
Make some errors more specific 2022-01-30 20:40:50 -05:00
Richard Feldman
c68dfdf61e
Drop some unused variants 2022-01-30 20:40:49 -05:00
Richard Feldman
fbedc3ba13
Extract common code from both branches 2022-01-30 20:40:49 -05:00
Richard Feldman
c3123de737
format hosted modules 2022-01-30 20:40:49 -05:00
Richard Feldman
484ce2fbc9
Parse hosted modules 2022-01-30 20:40:49 -05:00
Richard Feldman
a55ff62e6c
Merge remote-tracking branch 'origin/trunk' into expect-dont-panic 2022-01-30 20:22:26 -05:00
Chelsea Troy
4f8d0776b3 We got a test working for panicking with the appropriate number fo failures. Ultimatly we want:
+ An error maessage that says what the failures were
+ Not panicking (so these are effectively error productions)
2022-01-30 18:55:09 -06:00
Richard Feldman
8633cedf4d
Merge pull request #2430 from rtfeldman/frameworks
Make macOS frameworks link properly
2022-01-30 12:16:29 -05:00
Brian Carroll
c6babb30ba repl: Remove unused import 2022-01-30 16:32:42 +00:00
Brian Carroll
c8c51f0cdc repl: Move tests from roc_cli to roc_repl_cli 2022-01-30 16:20:48 +00:00
Richard Feldman
29caf5d301
Make macOS frameworks link properly 2022-01-30 11:01:31 -05:00
Anton-4
533afe96cd
fixed indentation; all tests working 2022-01-30 15:58:26 +01:00
Folkert de Vries
eec0f840bd
Merge pull request #2427 from rtfeldman/assort-parse-fixes
Assorted low-hanging-fruit bug fixes
2022-01-30 13:58:27 +01:00
Anton-4
95cd5ebab3
fixed cli_echo, base64_test 2022-01-30 13:07:52 +01:00
Brian Carroll
e168adfdf8 repl: update Earthfile 2022-01-30 09:12:52 +00:00
Brian Carroll
f098c6cb99 repl: initial working version with new crate structure 2022-01-30 09:12:29 +00:00
Brian Carroll
0f206121bd repl: move files from cli into repl-cli and repl-eval 2022-01-30 07:47:02 +00:00
ayazhafiz
b50bb9a4c7 Centralize closure type 2022-01-30 00:48:01 -05:00
ayazhafiz
e54917a063 Expose type mismatches between recursive types and types that aren't
Closes #2166
2022-01-30 00:21:45 -05:00
ayazhafiz
ee05d13802 Add test for type mismatch between optional and required fields
This comes from #2167 which has been fixed on trunk for some time, but
we didn't have a test for.

Closes #2167
2022-01-30 00:11:55 -05:00
ayazhafiz
84f8152514 Remove debug_assert that may legally check a false value
This may be false e.g. in the presence of a multiline string. Since the
parser is in a more stable state than when this was introduced, I think
this is OK to remove.

Closes #2398
2022-01-29 23:58:46 -05:00
ayazhafiz
8ae2d9d407 Parse interfaces with leading newlines
Closes #2420
2022-01-29 23:58:41 -05:00
Drew
227f06c4a5 Indent + remove old comments 2022-01-29 17:27:17 -06:00
hafiz
2d8bdfd863
Merge pull request #2417 from rtfeldman/i/2322
Inline polymorphic calls at usage sites
2022-01-29 16:13:43 -06:00
ayazhafiz
47a59c560c Make test use an i64 2022-01-29 15:04:22 -05:00
Anton-4
4f186113ae
bugfixes, more tests 2022-01-29 20:32:07 +01:00
Anton-4
76e0f31dec
successful ConsList.roc parse 2022-01-29 14:39:06 +01:00
Folkert de Vries
eb17d88ebb
Merge pull request #2414 from rtfeldman/repl_from_memory_trait
Implement `AppMemory` trait in the REPL
2022-01-29 14:01:02 +01:00
Brian Carroll
d7f10d80ae repl: Change LLVM macro to use address instead of pointer 2022-01-29 11:24:13 +00:00
Brian Carroll
06079ccde5 repl: inline a helper function 2022-01-29 11:17:20 +00:00
ayazhafiz
5943873654 Inline polymorphic calls at usage sites
This is a bit.. ugly, or at least seems suboptimal, but I can't think of
a better way to do it currently aside from demanding a uniform
representation, which we probably don't want to do.

Another option is something like the defunctionalization we perform
today, except also capturing potential uses of nested functions in the
closure tag of an encompassing lambda. So for example,

```
f = \x -> \y -> 1
```

would now record a lambdaset with the data `[Test.f
[TypeOfInnerClos1]]`, where `TypeOfInnerClos1` is e.g.
`[Test.f.innerClos1 I8, Test.f.innerClos1 I16]`, symbolizing that the
inner closure may be specialized to take an I8 or I16. Then at the time
that we create the capture set for `f`, we create a tag noting what
specialization should be used for the inner closure, and apply the
current defunctionalization algorithm. So effectively, the type of the
inner closure becomes a capture.

I'm not sure if this is any better, or if it has more problems.
@folkertdev any thoughts?

Closes #2322
2022-01-28 23:49:19 -05:00
Richard Feldman
f0b1c40e22
Merge pull request #2415 from rtfeldman/commit_signing_contributors
Added instructions on commit signing to CONTRIBUTORS
2022-01-28 14:41:12 -05:00
Anton-4
deb848da2d
fixed complex tag union annotation 2022-01-28 20:35:19 +01:00
Anton-4
6a0535d688
Fixed number list 2022-01-28 17:56:19 +01:00
Anton-4
548c0327c2
cleanup 2022-01-28 17:53:27 +01:00
Anton-4
72f2fac1a7
added Yubikey instructions 2022-01-28 17:51:58 +01:00
Brian Carroll
929ee7f560 Formatting 2022-01-28 16:50:05 +00:00
Anton-4
39e67747e6
added instructions for commit signing 2022-01-28 17:47:17 +01:00
Brian Carroll
e43cd8c399 repl: implement AppMemoryExternal::from_str 2022-01-28 13:30:26 +00:00
Brian Carroll
b466857b5e repl: rename module from_memory -> app_memory 2022-01-28 13:12:25 +00:00
Brian Carroll
3e35880513 repl: fix lifetime problem with app_memory in Env 2022-01-28 13:05:06 +00:00
Brian Carroll
382ae948e1 Merge branch 'trunk' of github.com:rtfeldman/roc into repl_from_memory_trait 2022-01-28 12:49:33 +00:00
Brian Carroll
0986d47ec6 repl: Remove some generics and use macros instead 2022-01-28 11:25:30 +00:00
Brian Carroll
46a3035759 repl: try putting the from_memory method on the AppMemory trait instead 2022-01-28 11:01:37 +00:00
Brian Carroll
6a9d31ec04 repl: Fix more type errors, but Rust still can't infer the FromMemory impls 2022-01-28 09:40:24 +00:00
Folkert de Vries
aff687d195
Merge pull request #2388 from rtfeldman/add_loop_examples
Add app examples for the new `fx.Effect.loop`
2022-01-27 23:49:00 +01:00