Skip to content
Snippets Groups Projects
Unverified Commit cb7432c7 authored by gumi's avatar gumi
Browse files

make OMATCH use actual values instead of true/false (too lazy to just remove it completely)

parent 18bbcfaa
No related branches found
No related tags found
No related merge requests found
......@@ -425,7 +425,7 @@ namespace option
#define OMATCH_BEGIN(expr) \
{ \
auto&& _omatch_var = (expr); \
switch (_omatch_var.is_some()) \
switch (_omatch_var.is_some() ? 1 : 0) \
{ \
{ \
{ \
......@@ -448,7 +448,7 @@ namespace option
break; \
} \
{ \
case true: \
case 1: \
{ \
auto&& var = *_omatch_var.ptr_or(nullptr); \
/*}}}}*/
......@@ -458,7 +458,7 @@ namespace option
break; \
} \
{ \
case false: \
case 0: \
{ \
/*}}}}*/
} // namespace option
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment