-
Notifications
You must be signed in to change notification settings - Fork 6
Description
Is your feature request related to a problem? Please describe.
In its current state, the requiresMainThread setting for expressions is never respected. In fact, the term "requiresMainThread" only occurs twice in the entirety of the ByteSkript source code: once in SyntaxElement.java, where it is defined, and once in ExprSystemInput.java, which is the only built-in expression to use the feature.
Describe the solution you'd like
The requiresMainThread setting should cause not only the expression's compiled code but also its handlers to be wrapped using a mechanism that allows the code to run only on the main thread of execution.
Describe alternatives you've considered
Not applicable.
Additional context
Project maintainers are likely already aware of the lack of implementation for this feature. This issue is not a feature request per se, rather it is meant to express the demand for the feature along with sparking discussion regarding possible implementation details.