Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixes for compatibility with zig 0.11.0 #190

Merged
merged 16 commits into from
Jul 8, 2023
Merged

fixes for compatibility with zig 0.11.0 #190

merged 16 commits into from
Jul 8, 2023

Conversation

radarroark
Copy link
Contributor

Not ready to merge. After these changes, the modules can individually build with 0.11.0-dev.3132+465272921 but the testrunner build command fails:

$ zig build --build-file test/testrunner/build.zig --prefix ./
zig build-exe testrunner Debug native: error: warning: FileNotFound: test/testrunner/src/main.zig
error: FileNotFound

Yours truly looked into it and found that it is a build system bug. Here's the fix: ziglang/zig#15717 Hopefully that can get into the release. Shake and bake!

@malcolmstill
Copy link
Owner

Yours truly looked into it and...

Legend!


Amazing @radarroark, thanks! With ziglang/zig#15602 having dropped and ziglang/zig#15705 dropping soon, there might also be some changes to make to the testrunner for parsing the .wast files.

@malcolmstill
Copy link
Owner

We'll also need to fix any casts ziglang/zig#16163

@radarroark
Copy link
Contributor Author

All casts should be fixed now. The powers that be think they can stop radar with all these breaking changes, but they only make me stronger...

Ah, but there's one more error in the testrunner. Looks like some kind of workaround but wasn't sure what to do with it:

zig-linux-x86_64-0.11.0-dev.3909+9e0ac4449/lib/std/json/static.zig:170:41: error: type '[]const testrunner.Command' has no members
    return ParseFromValueError || Source.NextError || Source.PeekError || Source.AllocError;
                                  ~~~~~~^~~~~~~~~~
zig-linux-x86_64-0.11.0-dev.3909+9e0ac4449/lib/std/json/static.zig:170:41: note: slice values have 'len' and 'ptr' members
src/testrunner.zig:93:28: note: called from here
        _ = json.ParseError([]const Command);
            ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~

@malcolmstill
Copy link
Owner

All casts should be fixed now. The powers that be think they can stop radar with all these breaking changes, but they only make me stronger...

Ah, but there's one more error in the testrunner. Looks like some kind of workaround but wasn't sure what to do with it:

zig-linux-x86_64-0.11.0-dev.3909+9e0ac4449/lib/std/json/static.zig:170:41: error: type '[]const testrunner.Command' has no members
    return ParseFromValueError || Source.NextError || Source.PeekError || Source.AllocError;
                                  ~~~~~~^~~~~~~~~~
zig-linux-x86_64-0.11.0-dev.3909+9e0ac4449/lib/std/json/static.zig:170:41: note: slice values have 'len' and 'ptr' members
src/testrunner.zig:93:28: note: called from here
        _ = json.ParseError([]const Command);
            ~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~

It might be with recent changes that those particular json.ParseError lines (which you are right were a workaround) aren't required.

However, I'm expecting because of ziglang/zig#15602 and ziglang/zig#15705 that the json parsing stuff will be totally broken anyway.

@malcolmstill
Copy link
Owner

@radarroark just fixed some conflicts on your branch for this change #192. I'm going to see if I can work around the testrunner not building and take a look at it what changes are required for the JSON parser stuff due to ziglang/zig#15602 and ziglang/zig#15705

@malcolmstill
Copy link
Owner

Ah so we can still build testrunner (modulo json parser changes) as long as we cd to its directory? We can just update the GitHub action to do that and it should be fine for the moment

@malcolmstill
Copy link
Owner

ziglang/zig#15981 may be what we need; trying it out now.

@malcolmstill
Copy link
Owner

Green light means go @radarroark!

@malcolmstill malcolmstill merged commit eace09d into malcolmstill:master Jul 8, 2023
@malcolmstill malcolmstill mentioned this pull request Jul 8, 2023
malcolmstill added a commit that referenced this pull request Jul 8, 2023
# Description

Follow up to #190 to fix the
`examples/fib` example + update code in README
@radarroark radarroark deleted the radar/build branch July 9, 2023 13:04
@malcolmstill
Copy link
Owner

Thanks for all the help on this @radarroark

@radarroark
Copy link
Contributor Author

You are welcome sir

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.

2 participants