[TRACKING ISSUE] aztec_noir: Attributes follow up work #1891
Labels
C-aztec.nr
Component: Aztec smart contract framework
T-tracking
Type: Tracking Issue. This contains tasklists.
Overview
Now that the initial work has been merged into our and noir's master branch (behind the aztec feature flag on the frontend). The job is refining and getting this work stable for the long term.
The goal of this issue is to coordinate the tasks planned, for reference, see a related tracking issue in Noir. Note; while the scope of these tracking issue collides. They are distinct; as Noir's deals with longer term solutions.
Relevant Literature
Along with the linked tracking issue above, there are the following resources:
Relevant Prs
Aztec
#[aztec(private)]
and#[aztec(public)
attributes #1735Noir
Future Work
Unsupported input params
Currently unable to have bool params.
Linked issue:
Return Values
Right now the application user cannot return from the function without calling:
This further leaks the internals of the kernel to the developer. We should aspire such that the user should return from functions using n
normal noir semantics.
Linked Issue:
Removing the Open Keyword
Right now all open functions have a return value keyword at the beginning. This is then included in the abi and included in the contract's function tree. And also determines that brillig should be generated for the function. The use of the
open
keyword was chosen aspublic
is considered overloaded. Consensus has such changed; thepublic
keyword is now deemed suitable for this.Linked Issue:
open
keyword, in favour of the public attribute #1886Removing the internal Keyword
Right now all internal functions have a return value keyword at the beginning. This is then included in the abi and included in the contract's function tree.
Linked Issue:
internal
keyword, in favour of an attribute #1916Auto import required resources from the aztec library
Currently; compilation will fail if the user has not included imports to the structures required. The following imports are required:
Compilation fails without this, and should be hidden
Linked issue:
Output Suitable Error message if using aztec noir features without the library installed.
Related to above, the ast information that is injected includes tokens that are only available if aztec noir is available. It is a footgun that installation will fail with syntax issues if the user has not included an import to the relevant files.
Linked Issue:
Handling Storage
Despite the existence of our macro syntax. The user still needs to call
let storage = Storage::init()
. at the beginning of each function call.Defining storage should be standardised such that when it is defined at the top of the file the developer does not need to worry about it too much.
Linked Issue:
Sub issue
Storage semantics have evolved over time, abstract away their definition from the developer.
#2163
Bugs
The text was updated successfully, but these errors were encountered: