Skip to content

Commit

Permalink
refactor: parseCommandLine (#60)
Browse files Browse the repository at this point in the history
* move comment

* use const char* instead of vstring for immutable strings

* move down integer defs

* use const char* for immutable data

* Add #defines for MODE_* constants

* use an enum instead of #define

* replace break with goto

This skips over an if statement, but the goto is only taken when the if
statement will be skipped anyway.

* remove superfluous continues

`continue` at the end of a loop is a no op. Use `else if` to put it
at the end of the block if necessary.

* add switch statement

The earlier goto replacement was to avoid the change to break here.

* combine common code

* formatting
  • Loading branch information
digama0 authored Feb 9, 2022
1 parent bf16e55 commit ed0a4f8
Showing 1 changed file with 161 additions and 189 deletions.
Loading

0 comments on commit ed0a4f8

Please sign in to comment.