dlugolecki.net.pl
Dziennik
Polecane
Software
projects
/
command.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Possibility to pass class method reference
[command.git]
/
tests
/
option
/
handles_boolean_value.cpp
diff --git
a/tests/option/handles_boolean_value.cpp
b/tests/option/handles_boolean_value.cpp
index 473a6b7047423cd259e80050c9f9cb0af98abfb1..7e3193aa069bfcf888292d67012c3dce9ea1dd5b 100644
(file)
--- a/
tests/option/handles_boolean_value.cpp
+++ b/
tests/option/handles_boolean_value.cpp
@@
-16,12
+16,12
@@
typedef bool OptionType;
OptionType test;
OptionType test;
-void function(OptionType value) {
+void
_
function(OptionType value) {
test = value;
}
int main() {
test = value;
}
int main() {
- Option<OptionType> option(NAME, "Option with boolean value", function);
+ Option<OptionType> option(NAME, "Option with boolean value",
_
function);
if (option.understand(OPTION1)) {
option.handle();
if (option.understand(OPTION1)) {
option.handle();
@@
-35,7
+35,7
@@
int main() {
cout << option.describe() << " handles " << FALSE << " values\n";
}
cout << option.describe() << " handles " << FALSE << " values\n";
}
- Option<OptionType> option2(NAME, "Option with boolean value", function);
+ Option<OptionType> option2(NAME, "Option with boolean value",
_
function);
if (option2.understand(OPTION2)) {
option2.handle();
if (option2.understand(OPTION2)) {
option2.handle();