petitparser / dart-petitparser

Dynamic parser combinators in Dart.
https://pub.dartlang.org/packages/petitparser
MIT License
457 stars 48 forks source link

Use break instead of code duplication #151

Closed f3ath closed 1 year ago

f3ath commented 1 year ago

Just a little nitpicky improvement. Seems a bit cleaner to my taste.

codecov-commenter commented 1 year ago

Codecov Report

Merging #151 (444a171) into main (cf333b4) will decrease coverage by 0.01%. The diff coverage is n/a.

:exclamation: Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

@@            Coverage Diff             @@
##             main     #151      +/-   ##
==========================================
- Coverage   99.09%   99.09%   -0.01%     
==========================================
  Files         104      104              
  Lines        2202     2201       -1     
==========================================
- Hits         2182     2181       -1     
  Misses         20       20              
Impacted Files Coverage Δ
lib/src/parser/repeater/possessive.dart 100.00% <ø> (ø)

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

renggli commented 1 year ago

Thank you, the same change could presumably be applied to lib/src/parser/repeater/separated.dart as well?