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

Inlining doesn't always work #2745

Closed
lukaszcz opened this issue Apr 19, 2024 · 0 comments · Fixed by #2842
Closed

Inlining doesn't always work #2745

lukaszcz opened this issue Apr 19, 2024 · 0 comments · Fixed by #2842
Assignees
Milestone

Comments

@lukaszcz
Copy link
Collaborator

For example in

module inline;

import Stdlib.Prelude open;

C : Int := 890534859083459034583;

main : Int := C;

the function C is not inlined in main.

@lukaszcz lukaszcz added this to the 0.6.2 milestone Apr 19, 2024
@lukaszcz lukaszcz self-assigned this Apr 19, 2024
@paulcadman paulcadman modified the milestones: 0.6.2, 0.6.3 Jun 12, 2024
lukaszcz added a commit that referenced this issue Jun 20, 2024
* Closes #2745 
* Adds inlining of immediate values, i.e., values that don't require
computation or memory allocation.
* Non-immediate zero-argument functions / values should not be inlined,
because when not inlined they can be computed only once.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants