File tree 1 file changed +8
-15
lines changed 1 file changed +8
-15
lines changed Original file line number Diff line number Diff line change 6
6
**************************************************************************************/
7
7
8
8
#include < mbed.h>
9
- #include < MemoryPool.h>
10
9
11
10
/* *************************************************************************************
12
11
* CLASS DECLARATION
15
14
template <class T , size_t QUEUE_SIZE = 16 >
16
15
class Shared
17
16
{
18
- public:
19
- Shared () {
20
- }
17
+ public:
21
18
22
- operator T ();
23
- void operator = (T const & other);
19
+ operator T ();
20
+ void operator = (T const & other);
24
21
25
- T& peek () {
26
- return _val;
27
- }
22
+ T & peek () { return _val; }
23
+ T & latest () { return peek (); }
28
24
29
- T& latest () {
30
- return peek ();
31
- }
32
25
33
- private:
26
+ private:
34
27
35
- T _val;
36
- rtos::Mail<T, QUEUE_SIZE> _mailbox;
28
+ T _val;
29
+ rtos::Mail<T, QUEUE_SIZE> _mailbox;
37
30
};
38
31
39
32
/* *************************************************************************************
You can’t perform that action at this time.
0 commit comments