Skip to content

Commit 731efab

Browse files
committed
updated examples because of c++11
1 parent 4e47e27 commit 731efab

2 files changed

Lines changed: 4 additions & 4 deletions

File tree

examples/Lock-1.cpp_

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@
33

44
void consumer(FastMutex &mut, Led &led)
55
{
6-
auto lock = Lock(mut);
6+
auto lock = Lock<FastMutex>(mut);
77
led.tick();
88
}
99

1010
void producer(FastMutex &mut)
1111
{
12-
auto lock = Lock(mut);
12+
auto lock = Lock<FastMutex>(mut);
1313
This::sleepFor(SEC);
1414
}
1515

examples/Lock-2.cpp_

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,13 @@ auto mtx = Mutex(mtxDefault);
66

77
void consumer()
88
{
9-
auto lock = Lock(mtx);
9+
auto lock = Lock<Mutex>(mtx);
1010
led.tick();
1111
}
1212

1313
void producer()
1414
{
15-
auto lock = Lock(mtx);
15+
auto lock = Lock<Mutex>(mtx);
1616
This::sleepFor(SEC);
1717
}
1818

0 commit comments

Comments
 (0)