Changeset 16283 for trunk/FACT++
- Timestamp:
- 05/26/13 21:19:13 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/FACT++/src/queue.h
r16094 r16283 141 141 } 142 142 143 #ifdef __GXX_EXPERIMENTAL_CXX0X__ 144 template<typename... _Args> 145 bool emplace(_Args&&... __args) 146 { 147 const std::lock_guard<std::mutex> lock(fMutex); 148 if (fState==kIdle) 149 return false; 150 151 std::list<T>::emplace_back(__args...); 152 fSize++; 153 154 fCond.notify_one(); 155 156 return true; 157 158 } 159 160 bool post(T &&val) { return emplace(std::move(val)); } 161 #endif 162 143 163 size_t size() const 144 164 {
Note:
See TracChangeset
for help on using the changeset viewer.