Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Interpret Context().sender as sender() #1557

Open
Shvandre opened this issue Jan 24, 2025 · 0 comments · May be fixed by #2427
Open

Interpret Context().sender as sender() #1557

Shvandre opened this issue Jan 24, 2025 · 0 comments · May be fixed by #2427
Assignees
Labels
kind: gas! Gas consumption and fee-related things scope: codegen Code generation, a.k.a. compiler backend (src/generator)
Milestone

Comments

@Shvandre
Copy link
Contributor

Doing it directly may break backward compatibility.

However we may interpret Context().sender as sender() - temporary solution. Which will be better in most cases

@anton-trunov anton-trunov added the kind: gas! Gas consumption and fee-related things label Jan 24, 2025
@anton-trunov anton-trunov changed the title Remove sender from Context() Interpret Context().sender as sender() Jan 24, 2025
@anton-trunov anton-trunov added the scope: codegen Code generation, a.k.a. compiler backend (src/generator) label Jan 24, 2025
@anton-trunov anton-trunov added this to the v1.6.0 milestone Jan 24, 2025
@anton-trunov anton-trunov modified the milestones: v1.6.0, v1.7.0 Jan 31, 2025
@Gusarich Gusarich self-assigned this Mar 18, 2025
Gusarich added a commit that referenced this issue Mar 18, 2025
This optimization replaces Context().sender field access with a direct call to sender() function for better gas efficiency, as recommended in the documentation.

Closes #1557
@novusnota novusnota modified the milestones: v1.7.0, v1.6.4, v1.6.5 Mar 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind: gas! Gas consumption and fee-related things scope: codegen Code generation, a.k.a. compiler backend (src/generator)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants