Skip to content

Commit 93457a5

Browse files
committed
Fixed option order handling
1 parent c69d2b1 commit 93457a5

File tree

3 files changed

+8
-29
lines changed

3 files changed

+8
-29
lines changed

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,5 @@
22
mrc
33
mrc-unit-test
44
mrc-bootstrap
5-
build/
5+
build/
6+
src/revision.hpp

src/mrc.cpp

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1028,12 +1028,6 @@ int main(int argc, char *argv[])
10281028
exit(0);
10291029
}
10301030

1031-
if (config.has("help") or config.operands().empty() or not config.has("output"))
1032-
{
1033-
std::cout << config << std::endl;
1034-
exit(config.has("help") ? 0 : 1);
1035-
}
1036-
10371031
if (config.has("header"))
10381032
{
10391033
mrsrc::rsrc data("mrsrc.h");
@@ -1053,6 +1047,12 @@ int main(int argc, char *argv[])
10531047
exit(0);
10541048
}
10551049

1050+
if (config.has("help") or config.operands().empty() or not config.has("output"))
1051+
{
1052+
std::cout << config << std::endl;
1053+
exit(config.has("help") ? 0 : 1);
1054+
}
1055+
10561056
VERBOSE = config.count("verbose");
10571057

10581058
// --------------------------------------------------------------------

src/revision.hpp

Lines changed: 0 additions & 22 deletions
This file was deleted.

0 commit comments

Comments
 (0)