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

Optimize code for instanceof and typeof #310

Open
jespa007 opened this issue Oct 7, 2021 · 0 comments
Open

Optimize code for instanceof and typeof #310

jespa007 opened this issue Oct 7, 2021 · 0 comments
Assignees

Comments

@jespa007
Copy link
Owner

jespa007 commented Oct 7, 2021

== Instanceof ==

Having the following code,

a instanceof TypeC
it generates the follwonf code,

load a
load TypeC
instanceof

It could be done in the following,

instanceof N/A, a|type, properties

== typeof ==

Having the following code,

typeof a == TypeC

It generates the following code,

load a
typeof

It could be simplied by,

typeof a

@jespa007 jespa007 added this to the ZetScript 2.0.0 milestone Oct 7, 2021
@jespa007 jespa007 self-assigned this Oct 7, 2021
@jespa007 jespa007 removed this from the ZetScript 2.1.0 milestone May 6, 2024
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

No branches or pull requests

1 participant