Skip to content

Stub out reflect.New and reflect.Zero #390

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

Closed
wants to merge 1 commit into from
Closed

Stub out reflect.New and reflect.Zero #390

wants to merge 1 commit into from

Conversation

tomelm
Copy link
Contributor

@tomelm tomelm commented Jun 3, 2019

This stubs out reflect.Zero and reflect.New. I believe this worked since the errors relating to these two functions went away when I tried to compile my project. Unfortunately I can't get make test running on my laptop so I can't run the full test suite. I'm going to try to get tiny-go setup on my other computer and see if I have better luck there.

Opening for now in case folks have any feedback on the PR or advice!

@aykevl
Copy link
Member

aykevl commented Jun 3, 2019

This looks good, will merge after #386 has been merged.

Unfortunately I can't get make test running on my laptop so I can't run the full test suite.

What OS do you have? On some systems (Debian/Ubuntu and macOS) you can run go test and it'll use the system-installed LLVM. Also, in theory if make works, make test should work as well (otherwise there is a bug).

@tomelm
Copy link
Contributor Author

tomelm commented Jun 3, 2019

I'm on macOS. I tried a handful of different things based on some Googling, including try to run go test directly, but had no luck: https://gist.github.com/tomelm/5ab50638a1cf1ac11cc1591f5cb38529

If that looks like a bug happy to open an issue, I had sort of figured it might've been my machine.

@aykevl
Copy link
Member

aykevl commented Jun 3, 2019

Have you tried just running go test -v, with no other flags/args?
go test -tags byollvm will fail because then you have to pass all the CGO_CFLAGS etc manually as environment variables.
go test ./... will fail because it will try to run tests of packages meant to be compiled with tinygo and not go: the source tree contains many directories with Go source files that cannot be compiled as they must be compiled with tinygo (mostly unrelated: a tinygo test is being worked on in #243).

@aykevl
Copy link
Member

aykevl commented Jun 3, 2019

Merged in 1047c9b. Thank you!

@aykevl aykevl closed this Jun 3, 2019
@tomelm
Copy link
Contributor Author

tomelm commented Jun 5, 2019

I haven't tried go test -v yet! I'll try that in the next few days when I can get some time to do that.

@tomelm
Copy link
Contributor Author

tomelm commented Jun 6, 2019

Looks all I needed was go test -v like you suggested. I saw a handful of main_test.go:168: failed to run: exec: "qemu-system-arm": executable file not found in $PATH but those seems to unrelated.

@aykevl
Copy link
Member

aykevl commented Jun 6, 2019

Yes, looks like go test is working. The error you're getting simply means that you don't have QEMU installed which is needed for some tests.

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