MatthieuDartiailh / bytecode

Python module to modify bytecode
https://bytecode.readthedocs.io/
MIT License
302 stars 38 forks source link

flags: fix the flag inference mechanism #56

Closed MatthieuDartiailh closed 4 years ago

MatthieuDartiailh commented 4 years ago

The existing implementation could easily generate invalid flags and was not easy to use to forcibly set a function as asynchronous or not. The new implementation address both limitations.

codecov-io commented 4 years ago

Codecov Report

Merging #56 into master will increase coverage by 3.89%. The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #56      +/-   ##
==========================================
+ Coverage   94.27%   98.16%   +3.89%     
==========================================
  Files          17        7      -10     
  Lines        2847     1420    -1427     
==========================================
- Hits         2684     1394    -1290     
+ Misses        163       26     -137
Impacted Files Coverage Δ
bytecode/bytecode.py 99.33% <100%> (+7.61%) :arrow_up:
bytecode/flags.py 100% <100%> (ø) :arrow_up:
bytecode/peephole_opt.py 94.38% <0%> (-0.02%) :arrow_down:
bytecode/tests/__init__.py
setup.py
bytecode/concrete.py 97.91% <0%> (+1.15%) :arrow_up:
bytecode/__init__.py 100% <0%> (+1.19%) :arrow_up:
bytecode/cfg.py 100% <0%> (+3.07%) :arrow_up:
bytecode/instr.py 99.48% <0%> (+5.18%) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 54d9ad7...12766ca. Read the comment docs.