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

asm grammar dosn't covers bracket syntax #4004

Open
dlangBugzillaToGithub opened this issue May 7, 2024 · 0 comments
Open

asm grammar dosn't covers bracket syntax #4004

dlangBugzillaToGithub opened this issue May 7, 2024 · 0 comments

Comments

@dlangBugzillaToGithub
Copy link

Mai Lapyst reported this on 2024-05-07T18:59:09Z

Transferred from https://issues.dlang.org/show_bug.cgi?id=24544

Description

The current grammar for asm statements does not cover the following code:

```d
asm {
  mov ECX, [ESP + 1]
}
```

While there exists a rule in `AsmBrExp` that allows for some brackets, they require an expression before the beginning bracket:

```d
void* pc;
asm {
  mov  pc[EBP],EBX
}
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant