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

brilirs: error on duplicate labels #331

Merged
merged 3 commits into from
Jul 27, 2024
Merged

brilirs: error on duplicate labels #331

merged 3 commits into from
Jul 27, 2024

Conversation

Pat-Lafon
Copy link
Contributor

The following is kinda fun because brili terminates but brilirs does not(Whether one takes the first or last occurrence of a label).

@main{
    jmp .A;
    .A:ret;
    .A:jmp  .A;
}

While brilirs can mirror this behavior, it can also be "helpful" by returning an error when it detects multiple labels as the specification/users intention is ambiguous.

2 commits to clean up the function first

@sampsyo
Copy link
Owner

sampsyo commented Jul 27, 2024

Awesome; seems great. I'm not sure if this restriction is in the spec, but it probably should be. 🤪

@sampsyo sampsyo merged commit 5416bb7 into sampsyo:main Jul 27, 2024
17 checks passed
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