fixes #682: rewrite no-constant-condition rule
Merge pull request #684 from michaelficarra/GH-682

fixes #682: rewrite no-constant-condition rule