Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 02e758e

Browse files
committedNov 5, 2021
Adding macro 'SINK_NON_BLOCKING' to instantiate non-blocking-sink.
Blocking sinks are instantiated via macro 'SINK'
1 parent a1cc560 commit 02e758e

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed
 

‎src/Arduino_Threads.h

+5
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,11 @@ public: \
7777
#define GET_SINK_MACRO(_1,_2,_3,NAME,...) NAME
7878
#define SINK(...) GET_SINK_MACRO(__VA_ARGS__, SINK_3_ARG, SINK_2_ARG)(__VA_ARGS__)
7979

80+
#define SINK_NON_BLOCKING(name, type) \
81+
public: \
82+
SinkNonBlocking<type> name{}; \
83+
private:
84+
8085
#define SHARED(name, type) \
8186
Shared<type> name;
8287

0 commit comments

Comments
 (0)
Please sign in to comment.