noir-lang / noir

Noir is a domain specific language for zero knowledge proofs
https://noir-lang.org
Apache License 2.0
823 stars 178 forks source link

Remove `SecondaryAttribute::Event` #3885

Open kevaundray opened 6 months ago

kevaundray commented 6 months ago

Problem

The enum variant SecondaryAttribute::Event is only used in the aztec_macros, we can remove this and use the is_custom_attribute function

Happy Case

.

Alternatives Considered

No response

Additional Context

No response

Would you like to submit a PR for this Issue?

No

Support Needs

No response

TomAFrench commented 6 months ago

We still have the concept of an event in the main compiler however so it wouldn't be a clean removal.

https://github.com/noir-lang/noir/blob/57eae42080d6a928e8010c6bc77489964a5777ef/compiler/noirc_frontend/src/hir/def_map/mod.rs#L195-L205

kevaundray commented 6 months ago

We still have the concept of an event in the main compiler however so it wouldn't be a clean removal.

https://github.com/noir-lang/noir/blob/57eae42080d6a928e8010c6bc77489964a5777ef/compiler/noirc_frontend/src/hir/def_map/mod.rs#L195-L205

Yeah I think we'd need to have the concept of a primary attribute that is able to put things in the abi, ie #[abi(event)]