Skip to content

Comments

Scope storage vars only to fns within the utxo block#114

Open
SpaceManiac wants to merge 8 commits intomainfrom
tad/compiler-internals
Open

Scope storage vars only to fns within the utxo block#114
SpaceManiac wants to merge 8 commits intomainfrom
tad/compiler-internals

Conversation

@SpaceManiac
Copy link
Contributor

  1. Start a new scope for each utxo block and compile its functions in that context.
  2. Put storage vars in that scope rather than the global scope.
  3. Adjust the synthetic get-storage and set-storage functions to also be compiled in this scope.
  4. Prepend Utxo name to synthetic storage functions to avoid collisions.

Also, Identifier's span is now non-optional internally. DUMMY_SPAN is added as a constant for cases where no span is available. Accessors representing the old use patterns have been added.

Signed-off-by: Tad Hardesty <tad.hardesty@midnight.foundation>
Signed-off-by: Tad Hardesty <tad.hardesty@midnight.foundation>
Signed-off-by: Tad Hardesty <tad.hardesty@midnight.foundation>
Signed-off-by: Tad Hardesty <tad.hardesty@midnight.foundation>
Signed-off-by: Tad Hardesty <tad.hardesty@midnight.foundation>
Signed-off-by: Tad Hardesty <tad.hardesty@midnight.foundation>
Signed-off-by: Tad Hardesty <tad.hardesty@midnight.foundation>
Signed-off-by: Tad Hardesty <tad.hardesty@midnight.foundation>
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

Successfully merging this pull request may close these issues.

1 participant