JSAbrahams / mamba

🐍 The Mamba programming language, because we care about safety
MIT License
85 stars 3 forks source link

Fix redundant ABC #357

Closed JSAbrahams closed 2 years ago

JSAbrahams commented 2 years ago

Relevant issues

Summary

If a class has a parent which is already abstract, then we don't need to mark this class as abstract. We do this check recursively.

Also added context to generate stage to perform this check. More advanced language constructs could benefit from a context in the generate stage in future.

Added Tests

codecov[bot] commented 2 years ago

Codecov Report

Merging #357 (a09e8a5) into develop (d80cd0b) will decrease coverage by 0.00%. The diff coverage is 90.38%.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop     #357      +/-   ##
===========================================
- Coverage    86.96%   86.96%   -0.01%     
===========================================
  Files          108      108              
  Lines        11641    11657      +16     
===========================================
+ Hits         10124    10137      +13     
- Misses        1517     1520       +3