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

GETIMPORT constant kmode #31

Closed
TheGreatSageEqualToHeaven opened this issue Apr 4, 2024 · 0 comments · Fixed by #42
Closed

GETIMPORT constant kmode #31

TheGreatSageEqualToHeaven opened this issue Apr 4, 2024 · 0 comments · Fixed by #42
Assignees
Labels
enhancement New feature or request

Comments

@TheGreatSageEqualToHeaven
Copy link
Member

We already have an optimisation to pre-process the bitwise operations but we should provide a setting to optionally treat these as a constant. We will likely use a staticEnvironment setting in luau_settings to define where the constant globals will be and add a setting useImportConstants

@TheGreatSageEqualToHeaven TheGreatSageEqualToHeaven added the enhancement New feature or request label Apr 4, 2024
@SnorlaxAssist SnorlaxAssist linked a pull request May 31, 2024 that will close this issue
TheGreatSageEqualToHeaven pushed a commit that referenced this issue May 31, 2024
Closes #31

```lua
local settings = Fiu.luau_newsettings()
settings.useImportConstants = true
settings.staticEnvironment = {
	math = math
}
```
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

Successfully merging a pull request may close this issue.

2 participants