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

Avoid requiring the bit number of bit, set, and res to be constant #8

Open
ISSOtm opened this issue Jan 23, 2025 · 2 comments
Open
Labels
enhancement New feature or request

Comments

@ISSOtm
Copy link
Owner

ISSOtm commented Jan 23, 2025

It is feasible to defer computation of the opcode byte to the linker.

@ISSOtm ISSOtm added the enhancement New feature or request label Jan 23, 2025
@Rangi42
Copy link

Rangi42 commented Jan 24, 2025

Was this motivated by some particular project's example that could benefit from link-time bit indexes?

@Rangi42
Copy link

Rangi42 commented Jan 24, 2025

Oh, I see, https://github.com/ISSOtm/gb-vwf/blob/e850d8431a868ca738002b2ee0b2b0ade9c63d71/vwf.asm#L212-L214:

; Definitions for the various bits in `wFlags`.
; FIXME: it would be neater to define these next to `wFlags`, but RGBDS 0.6.1 requires the first
; operand to `bit`, `set`, and `res` to be constant...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants