Skip to content

A lazier approach to precompilation #358

@ghost

Description

Having dedicated precompile statements is fine for libraries, but not ideal for applications.
What if function calls could be precompiled when they are called? "just in time precompilation"

Let's say there is a macro

@precompile_on_demand f(...)

That wraps the call in a separate module, precompiles that module, and replaces the call with the call from that module?

module PrecompMod
@precompile_all_calls f(...)
end
using .PrecompMod
PrecompMod.f(...)

maybe this can be done with Cassette?

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