Skip to content

Question: event hook on new_thread/new_work? #531

Open
@wbthomason

Description

@wbthomason

Is there a way for embedders to get a callback on new_thread or new_work? This would be useful for for e.g. modifying _G in the thread's lua_State.

It seems as though #350 may already provide this, but I don't see a way to determine (in the lua_CFpcall callback) from where the callback has been called. Perhaps this could be a new flag, e.g. LUVF_CALLBACK_NEWTHREAD, indicating to the callback implementer that it should (if desired) perform initialization work on the provided lua_State?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions