Skip to content

[Docs] Examples in device_context.mojo mention the recently deleted enqueue_function #5724

@ckoparkar

Description

@ckoparkar

Where is the problem?

https://docs.modular.com/mojo/std/gpu/host/device_context/DeviceContext/

What can we do better?

A lot of examples in device_context.mojo mention enqueue_function which was deleted in b77cf50. These should be updated to use the _checked or _unchecked variant.

Also, when I run any example which has with DeviceContext() as ctx: I see the following: error: cannot call function that may raise in a context that cannot raise. Adding a def main(): over it solves the issue.

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs TriageIssue needs to be routed/triaged to a particular team stilldocumentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions