INRIA / INRIA/spoon

`VisitorPartialEvaluator` should group constant terms when possible like `((a + 2) + b) + 3 = (a + b) + 5`

Open
#5,309 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Java
Stars
2k
Forks
392
Avg merge
11h 24m
Merged PRs (30d)
36

Description

Some things to consider:
- might not want to do this when function calls are involved, because they could have side-effects. On the other hand if the order of the calls do not change, it should not make a difference? For example: `doA() + 2 + doB() + 3` should not be turned into `doB() + doA() + 5`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.