Skip to content

Commit

Permalink
update some note
Browse files Browse the repository at this point in the history
  • Loading branch information
ahangsu committed Nov 23, 2022
1 parent 1f96d76 commit c5c7715
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pyteal/ast/abi/type.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,10 @@ def __init__(self, spec: TypeSpec) -> None:
assert proto.mem_layout
local_types = proto.mem_layout.local_stack_types

if len(local_types) < 128:
# NOTE: you can have at most 128 local variables.
# len(local_types) + 1 computes the resulting length,
# should be <= 128
if len(local_types) + 1 <= 128:
local_types.append(self._type_spec.storage_type())
self._stored_value = FrameVar(proto, len(local_types) - 1)
return
Expand Down

0 comments on commit c5c7715

Please sign in to comment.