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

bug: self-referential types crash the VM #2008

Open
deelawn opened this issue Apr 30, 2024 · 0 comments · May be fixed by #2081
Open

bug: self-referential types crash the VM #2008

deelawn opened this issue Apr 30, 2024 · 0 comments · May be fixed by #2081
Assignees
Labels
🐞 bug Something isn't working 📦 🤖 gnovm Issues or PRs gnovm related

Comments

@deelawn
Copy link
Contributor

deelawn commented Apr 30, 2024

Self-referential types that are prohibited in go can cause the VM to crash. I think we need to check somewhere in the preprocessor that for this. Here is the example to reproduce the issue:

package main

type S struct {
        T S
}

func main() {
        var a, b S
        println(a == b)
}
@deelawn deelawn added 🐞 bug Something isn't working 📦 🤖 gnovm Issues or PRs gnovm related labels Apr 30, 2024
@ltzmaxwell ltzmaxwell self-assigned this May 7, 2024
@Kouteki Kouteki added this to the 🏗4️⃣ test4.gno.land milestone May 10, 2024
@ltzmaxwell ltzmaxwell linked a pull request May 13, 2024 that will close this issue
5 tasks
@zivkovicmilos zivkovicmilos linked a pull request May 15, 2024 that will close this issue
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐞 bug Something isn't working 📦 🤖 gnovm Issues or PRs gnovm related
Projects
Status: In Progress
Development

Successfully merging a pull request may close this issue.

3 participants