Skip to content

Commit

Permalink
updated examples because of c++11
Browse files Browse the repository at this point in the history
  • Loading branch information
rajszym committed Jul 8, 2020
1 parent 4e47e27 commit 731efab
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions examples/Lock-1.cpp_
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@

void consumer(FastMutex &mut, Led &led)
{
auto lock = Lock(mut);
auto lock = Lock<FastMutex>(mut);
led.tick();
}

void producer(FastMutex &mut)
{
auto lock = Lock(mut);
auto lock = Lock<FastMutex>(mut);
This::sleepFor(SEC);
}

Expand Down
4 changes: 2 additions & 2 deletions examples/Lock-2.cpp_
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ auto mtx = Mutex(mtxDefault);

void consumer()
{
auto lock = Lock(mtx);
auto lock = Lock<Mutex>(mtx);
led.tick();
}

void producer()
{
auto lock = Lock(mtx);
auto lock = Lock<Mutex>(mtx);
This::sleepFor(SEC);
}

Expand Down

0 comments on commit 731efab

Please sign in to comment.