Child contract entrypoints can be called like from namespaces #412

Closed
opened 2022-09-02 00:30:27 +09:00 by zxq9 · 0 comments
zxq9 commented 2022-09-02 00:30:27 +09:00 (Migrated from gitlab.com)

Created by: radrow

Reproduction

Compile the following contract:

contract F =
  entrypoint g() = 3333

contract C =
  entrypoint f() = F.g()

Then calling f() would crash in runtime.

Fix

Child contracts should not be treated as namespaces. That code should not compile in the first place.

*Created by: radrow* ### Reproduction Compile the following contract: ``` contract F = entrypoint g() = 3333 contract C = entrypoint f() = F.g() ``` Then calling `f()` would crash in runtime. ### Fix Child contracts should not be treated as namespaces. That code should not compile in the first place.
Sign in to join this conversation.
No Milestone
No project
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: QPQ-AG/sophia#412
No description provided.