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
Remove event
type and keyword
#717
Comments
What effect does this have (or would it have in the future) on indexed fields? |
I agree we should do this. This is basically the only thing holding us back from adding an |
I think the main advantages of treating events as structs are:
|
Currently, we use
event
type defined withevent
keyword to emit an event.But actually, we could handle
event
types in the same way as types defined with thestruct
keyword, i.e., normal user-defined struct.The only difference between
event
andstruct
would betopic
, so it would be necessary to introduce some special syntax or language features that enable it to be specified.Currently, I'd like to propose allowing
@[indexed]
or@[topic]
attribute in the field like below.In the short-term plan, we could treat
@[indexed]
attribute specially, then generalize the attribute feature in the long-term plan.The text was updated successfully, but these errors were encountered: