Skip to content

Tutorial mentions non-existing variable #1958

Closed
@salty-horse

Description

@salty-horse

In the "Spawning a task" section of the tutorial, the text refers to thechild_task variable in this snippet:

let some_value = 22;
task::spawn {||
    std::io::println("This executes in the child task.");
    std::io::println(#fmt("%d", some_value));
}

No child_task is mentioned. From subsequent examples, I assume it should be let child_task = task::spawn {||.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions