Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
EIC
NPDet
Commits
cccebf7f
Commit
cccebf7f
authored
Sep 21, 2021
by
Wouter Deconinck
Browse files
Logical parentheses in command line parsing
parent
82c5644b
Pipeline
#18941
passed with stages
in 33 seconds
Changes
1
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
src/tools/src/npdet_fields.cxx
View file @
cccebf7f
...
...
@@ -77,14 +77,14 @@ settings cmdline_settings(int argc, char* argv[]) {
"draw mode:"
%
(
command
(
"draw"
),
// values("component").set(s.field_comps),
option
(
"--Nsteps"
)
&
number
(
"Nsteps"
,
s
.
step_size
)
%
"number of steps to evaluate"
,
option
(
"--step"
)
&
number
(
"step"
,
s
.
step_size
)
%
"step size"
,
option
(
"--step"
)
&
number
(
"step"
,
s
.
step_size
)
%
"step size"
,
option
(
"--start"
)
&
(
number
(
"x"
,
s
.
x0
).
if_missing
([]
{
std
::
cout
<<
"x missing!
\n
"
;
}),
number
(
"y"
,
s
.
y0
).
if_missing
([]
{
std
::
cout
<<
"y missing!
\n
"
;
}),
number
(
"z"
,
s
.
z0
).
if_missing
([]
{
std
::
cout
<<
"z missing!
\n
"
;
})),
(
option
(
"--end"
).
set
(
s
.
with_end_point
,
true
)
&
(
number
(
"x1"
,
s
.
x1
).
if_missing
([]
{
std
::
cout
<<
"x1 missing!
\n
"
;
}),
number
(
"y1"
,
s
.
y1
).
if_missing
([]
{
std
::
cout
<<
"y1 missing!
\n
"
;
}),
number
(
"z1"
,
s
.
z1
).
if_missing
([]
{
std
::
cout
<<
"z1 missing!
\n
"
;
}))
|
option
(
"--direction"
)
&
number
(
"z1"
,
s
.
z1
).
if_missing
([]
{
std
::
cout
<<
"z1 missing!
\n
"
;
}))
)
|
(
option
(
"--direction"
)
&
(
number
(
"x2"
,
s
.
x2
).
if_missing
([]
{
std
::
cout
<<
"x2 missing!
\n
"
;
}),
number
(
"y2"
,
s
.
y2
).
if_missing
([]
{
std
::
cout
<<
"y2 missing!
\n
"
;
}),
number
(
"z2"
,
s
.
z2
).
if_missing
([]
{
std
::
cout
<<
"z2 missing!
\n
"
;
})))
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment