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

Type with reference to itself crashes the compiler #21732

Closed
fleximus opened this issue Jun 25, 2024 · 0 comments · Fixed by #21733
Closed

Type with reference to itself crashes the compiler #21732

fleximus opened this issue Jun 25, 2024 · 0 comments · Fixed by #21733
Assignees
Labels
Bug This tag is applied to issues which reports bugs. Unit: Checker Bugs/feature requests, that are related to the type checker.

Comments

@fleximus
Copy link

fleximus commented Jun 25, 2024

Describe the bug

Adding a type with reference to itself will make the compiler crash

Reproduction Steps

type FnType = fn (string) FnType

fn main() {
    println("OK")
}

Expected Behavior

Compile or throw an error

Current Behavior

Segmentation fault (core dumped)

Possible Solution

No response

Additional Information/Context

No response

V version

V 0.4.6 d364e61

Environment details (OS name and version, etc.)

V full version: V 0.4.6 96751ed.d364e61
OS: linux, Linux Mint 21.3

CC version: cc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0
thirdparty/tcc status: thirdparty-linux-amd64 40e5cbb5

Note

You can use the 👍 reaction to increase the issue's priority for developers.

Please note that only the 👍 reaction to the issue itself counts as a vote.
Other reactions and those to comments will not be taken into account.

@fleximus fleximus added the Bug This tag is applied to issues which reports bugs. label Jun 25, 2024
@felipensp felipensp added the Unit: Checker Bugs/feature requests, that are related to the type checker. label Jun 25, 2024
@Delta456 Delta456 self-assigned this Jun 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug This tag is applied to issues which reports bugs. Unit: Checker Bugs/feature requests, that are related to the type checker.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants