anvaka / common-words

visualization of common words in different programming languages
https://anvaka.github.io/common-words
MIT License
506 stars 27 forks source link

else if does not count the if ? #2

Closed uael closed 7 years ago

uael commented 7 years ago

It seems that when "else if" is matched, the "if" isn't counted

anvaka commented 7 years ago

Thank you for reporting.

While top words were correct, the usage counters were skewed. I was showing number of occurrences for a top word only inside top lines.

This should be fixed by https://github.com/anvaka/common-words/commit/7966bc66970ac198965983a21cf2c96db0e8c6ba

Top words now show absolute word usage count, while context lines show how many such line appeared.