Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
Institute of Technical Acoustics (ITA)
toolbox
Commits
ec28dbd8
Commit
ec28dbd8
authored
Dec 12, 2016
by
Jan-Gerrit Richter
Browse files
ita_parse_arguments: disabled warning if unknown parameters are returned
parent
b7aa1751
Changes
2
Hide whitespace changes
Inline
Side-by-side
Debug/test_ita_parse_arguments.m
View file @
ec28dbd8
...
...
@@ -31,3 +31,15 @@ end
% -
%% test moving unknown options to second output
struct
.
testpar
=
1
;
struct
.
testpar2
=
2
;
parCell
=
{
'testpar'
,
2
,
'testpar2'
,
4
,
'unknown'
,
6
};
% this should give a warning
[
sArgs
]
=
ita_parse_arguments
(
struct
,
parCell
);
% this should not
[
sArgs
,
unknownParams
]
=
ita_parse_arguments
(
struct
,
parCell
);
kernel/StandardRoutines/ita_parse_arguments.m
View file @
ec28dbd8
...
...
@@ -300,7 +300,9 @@ while (idx <= nArguments) % go through all arguments
end
if
notFoundArguments
==
1
ita_verbose_info
([
thisFuncStr
callFuncStr
'Some arguments could not be found in the struct. They are returned separately.'
],
0
);
if
nargout
<
2
ita_verbose_info
([
thisFuncStr
callFuncStr
'Some arguments could not be found in the struct. They are returned separately.'
],
0
);
end
end
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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