mirror of
https://gitee.com/acl-dev/acl.git
synced 2024-11-30 10:57:34 +08:00
rename fiber_sem_t_def to fiber_sem_t_sync.
This commit is contained in:
parent
8265c1c330
commit
54a295b0f2
@ -8,13 +8,13 @@ struct ACL_FIBER_SEM;
|
||||
namespace acl {
|
||||
|
||||
typedef enum {
|
||||
fiber_sem_t_def = 0,
|
||||
fiber_sem_t_sync = 0,
|
||||
fiber_sem_t_async = (1 << 0),
|
||||
} fiber_sem_attr_t;
|
||||
|
||||
class FIBER_CPP_API fiber_sem {
|
||||
public:
|
||||
fiber_sem(int max, fiber_sem_attr_t attr = fiber_sem_t_def);
|
||||
fiber_sem(int max, fiber_sem_attr_t attr = fiber_sem_t_async);
|
||||
~fiber_sem(void);
|
||||
|
||||
int wait(void);
|
||||
@ -50,7 +50,7 @@ template<typename T>
|
||||
class fiber_sbox {
|
||||
public:
|
||||
fiber_sbox(bool free_obj = true, bool async = true)
|
||||
: sem_(0, async ? fiber_sem_t_async : fiber_sem_t_def)
|
||||
: sem_(0, async ? fiber_sem_t_async : fiber_sem_t_sync)
|
||||
, free_obj_(free_obj) {}
|
||||
|
||||
~fiber_sbox(void) { clear(free_obj_); }
|
||||
@ -104,7 +104,7 @@ template<typename T>
|
||||
class fiber_sbox2 {
|
||||
public:
|
||||
fiber_sbox2(bool async = true)
|
||||
: sem_(0, async ? fiber_sem_t_async : fiber_sem_t_def) {}
|
||||
: sem_(0, async ? fiber_sem_t_async : fiber_sem_t_sync) {}
|
||||
|
||||
~fiber_sbox2(void) {}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user