diff options
| author | datdenkikniet <jcdra1@gmail.com> | 2023-04-23 15:33:56 +0200 |
|---|---|---|
| committer | datdenkikniet <jcdra1@gmail.com> | 2023-05-11 19:20:58 +0200 |
| commit | a66540efa014b3716d252612bfc7f8f17ed765c4 (patch) | |
| tree | 5efe4cf769b9941c5ce387649ee8ed15470ca507 /book/en/src/migration_v1_v2 | |
| parent | 0807aa548c865d12746ce17aa1c17f7968b139a9 (diff) | |
Disable the playground on all of these
Diffstat (limited to 'book/en/src/migration_v1_v2')
| -rw-r--r-- | book/en/src/migration_v1_v2/async_tasks.md | 6 | ||||
| -rw-r--r-- | book/en/src/migration_v1_v2/complete_example.md | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/book/en/src/migration_v1_v2/async_tasks.md b/book/en/src/migration_v1_v2/async_tasks.md index 54e0893..60f7033 100644 --- a/book/en/src/migration_v1_v2/async_tasks.md +++ b/book/en/src/migration_v1_v2/async_tasks.md @@ -10,7 +10,7 @@ All software tasks are now required to be `async`. All of the tasks in your project that do not bind to an interrupt must now be an `async fn`. For example: -``` rust +``` rust,noplayground #[task( local = [ some_resource ], shared = [ my_shared_resource ], @@ -24,7 +24,7 @@ fn my_task(cx: my_task::Context) { becomes -``` rust +``` rust,noplayground #[task( local = [ some_resource ], shared = [ my_shared_resource ], @@ -40,7 +40,7 @@ async fn my_task(cx: my_task::Context) { The new `async` software tasks are allowed to run forever, on one precondition: **there must be an `await` within the infinite loop of the task**. An example of such a task: -``` rust +``` rust,noplayground #[task(local = [ my_channel ] )] async fn my_task_that_runs_forever(cx: my_task_that_runs_forever::Context) { loop { diff --git a/book/en/src/migration_v1_v2/complete_example.md b/book/en/src/migration_v1_v2/complete_example.md index dc29b25..19a746a 100644 --- a/book/en/src/migration_v1_v2/complete_example.md +++ b/book/en/src/migration_v1_v2/complete_example.md @@ -86,7 +86,7 @@ mod app { # V2.0.0 -``` rust +``` rust,noplayground {{ #include ../../../../examples/stm32f3_blinky/src/main.rs }} ``` |
