Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
E
epics-wb
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
misc
epics-wb
Commits
3dc44ee5
Commit
3dc44ee5
authored
Jun 15, 2015
by
Benoit Rat
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
asynWB: improve AsynStatusObj
parent
4a166dda
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
3 deletions
+5
-3
asynWBPortDrvr.cpp
src/asynWBPortDrvr.cpp
+2
-2
asynWBPortDrvr.h
src/asynWBPortDrvr.h
+3
-1
No files found.
src/asynWBPortDrvr.cpp
View file @
3dc44ee5
...
...
@@ -23,8 +23,8 @@
#include "asynWBPortDrvr.h"
#include "awbpd_trace.h"
#define TRACE_P_VDEBUG(...) TRACE_P_DEBUG( __VA_ARGS__)
#define TRACE_P_VVDEBUG(...) TRACE_P_DEBUG( __VA_ARGS__)
#define TRACE_P_VDEBUG(...)
//
TRACE_P_DEBUG( __VA_ARGS__)
#define TRACE_P_VVDEBUG(...)
//
TRACE_P_DEBUG( __VA_ARGS__)
/**
* Constructor for the asynWBPortDrvr class.
...
...
src/asynWBPortDrvr.h
View file @
3dc44ee5
...
...
@@ -36,8 +36,10 @@ struct AsynWBField {
*/
struct
AsynStatusObj
{
asynStatus
data
;
AsynStatusObj
()
:
data
(
asynSuccess
)
{};
AsynStatusObj
(
asynStatus
data
)
:
data
(
data
)
{};
AsynStatusObj
&
operator
&=
(
const
asynStatus
&
data
)
{
if
(
data
!=
asynSuccess
||
(
this
->
data
!=
asynSuccess
&&
data
!=
asynSuccess
))
{
this
->
data
=
data
;}
return
*
this
;
}
AsynStatusObj
&
operator
&=
(
bool
data
)
{
if
(
data
==
false
)
{
this
->
data
=
asynError
;}
return
*
this
;
}
AsynStatusObj
&
operator
&=
(
const
asynStatus
&
data
)
{
if
(
data
!=
asynSuccess
)
{
this
->
data
=
data
;}
return
*
this
;
}
AsynStatusObj
&
operator
=
(
const
asynStatus
&
data
)
{
this
->
data
=
data
;
return
*
this
;
}
bool
operator
==
(
asynStatus
data
)
const
{
return
(
this
->
data
==
data
);
}
asynStatus
operator
&
()
const
{
return
this
->
data
;
};
...
...
Write
Preview
Markdown
is supported
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