vyperlang / vyper

Pythonic Smart Contract Language for the EVM
https://vyperlang.org
Other
4.83k stars 789 forks source link

fix[codegen]: same symbol jumpdest merge #3982

Closed harkal closed 3 months ago

harkal commented 3 months ago

What I did

Fixed assembly optimizer case where trying to optimize two consecutive JUMPDESTs with the same symbol results in no code change, while returning of True in changes.

How I did it

Made the optimization step return False as it should.

How to verify it

Through the included tests

Commit message

Updates the assembly optimizer to return `False` when trying to 
optimize two consecutive `JUMPDEST`s with the same symbol. 
It used to return `True` when no change was made.

+ unit tests

Description for the changelog

Cute Animal Picture

![Put a link to a cute animal picture inside the parenthesis-->]()