Skip to content

Conversation

@lukewilliamboswell
Copy link
Collaborator

@lukewilliamboswell lukewilliamboswell commented Jul 1, 2024

This is a twin PR for roc-lang/roc#6836 in the roc-lang/roc repo.

It updates the FFI in this platform to return exclusively Tasks, as well as removes this platform's Task module (and InternalTask).

@lukewilliamboswell lukewilliamboswell changed the title Add Task as a builtin module/type WIP Add Task as a builtin module/type Jul 3, 2024
@lukewilliamboswell
Copy link
Collaborator Author

lukewilliamboswell commented Aug 13, 2024

Rebased on main, and updated to use latest roc-lang/roc branch.

Currently fails with the following;

$ ROC=roc EXAMPLES_DIR=examples/ bash ci/all_tests.sh
<------SNIP------>
++ uname -m
+ architecture=arm64
+ for roc_file in '$EXAMPLES_DIR*.roc'
+ roc build --prebuilt-platform --linker=legacy examples/command.roc
0 errors and 0 warnings found in 260 ms
 while successfully building:

    examples/command
+ for roc_file in '$EXAMPLES_DIR*.roc'
+ roc build --prebuilt-platform --linker=legacy examples/dir.roc
thread 'main' panicked at /Users/luke/.cargo/git/checkouts/inkwell-55729a4c43239568/d1a5963/src/values/enums.rs:302:13:
Found StructValue(StructValue { struct_value: Value { name: "load_result", address: 0x600000866900, is_const: false, is_null: false, is_undef: false, llvm_value: "  %load_result = load { [0 x i64], [3 x i64], i8, [7 x i8] }, ptr %result_value, align 8, !dbg !10", llvm_type: "{ [0 x i64], [3 x i64], i8, [7 x i8] }" } }) but expected PointerValue variant
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

@Anton-4
Copy link
Collaborator

Anton-4 commented Aug 21, 2024

I apologize for the many commits, I'm currently on Ubuntu and it's easiest to make all the changes using the github website.

@Anton-4
Copy link
Collaborator

Anton-4 commented Aug 21, 2024

Right, backpassing is deprecated now, need to update some code...

@Anton-4
Copy link
Collaborator

Anton-4 commented Aug 21, 2024

I'm going to try to make an llm perform all the backpassing changes :p

@lukewilliamboswell lukewilliamboswell changed the title WIP Add Task as a builtin module/type Builtin Task upgrade Aug 24, 2024
@lukewilliamboswell lukewilliamboswell changed the title Builtin Task upgrade Add Task as a builtin module/type Aug 24, 2024
smores56
smores56 previously approved these changes Aug 25, 2024
smores56
smores56 previously approved these changes Aug 26, 2024
smores56
smores56 previously approved these changes Aug 26, 2024
We can probably leave this out, the user should be familiar with the basics once they use this example.
Anton-4
Anton-4 previously approved these changes Aug 26, 2024
@smores56
Copy link
Collaborator

I'll clean this up now!

@smores56
Copy link
Collaborator

Not much was really needed, we are now just waiting for a basic-cli v0.15 release to update our scripts with, then we can merge this

smores56
smores56 previously approved these changes Aug 30, 2024
@smores56 smores56 merged commit 5eb624e into roc-lang:main Aug 30, 2024
@smores56 smores56 deleted the builtin-task branch August 30, 2024 18:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants