mirror of
https://github.com/roc-lang/roc.git
synced 2024-11-12 23:50:20 +03:00
Wrap a record in Box before passing it to the host, to work around an ABI issue
This commit is contained in:
parent
3c506eb79c
commit
c50cbd265a
@ -7,4 +7,4 @@ putLine : Str -> Effect {}
|
||||
|
||||
getLine : Effect Str
|
||||
|
||||
sendRequest : Request -> Effect Response
|
||||
sendRequest : Box Request -> Effect Response
|
||||
|
@ -104,6 +104,7 @@ errorToString = \err ->
|
||||
|
||||
send : Request -> Task Str Error [Network [Http]*]*
|
||||
send = \req ->
|
||||
Effect.sendRequest req
|
||||
# TODO: Fix our C ABI codegen so that we don't this Box.box heap allocation
|
||||
Effect.sendRequest (Box.box req)
|
||||
|> Effect.map handleStringResponse
|
||||
|> InternalTask.fromEffect
|
||||
|
Loading…
Reference in New Issue
Block a user