jit macro
This commit is contained in:
parent
69afdd61a6
commit
61fb6cdf05
15
src/utils.jl
15
src/utils.jl
@ -153,3 +153,18 @@ function jacobian(m,x)
|
||||
end
|
||||
J'
|
||||
end
|
||||
|
||||
"""
|
||||
@jit ...
|
||||
|
||||
The `@jit` annotation can be applied to any code, and the code will be compiled
|
||||
for performance.
|
||||
|
||||
@jit f(x) = @jit(x) + @jit(x)
|
||||
|
||||
Note that compilation happens regardless of the `@jit` macro, so it should only
|
||||
be used for aesthetic purposes, or by recovering Python users.
|
||||
"""
|
||||
macro jit(ex)
|
||||
esc(ex)
|
||||
end
|
||||
|
Loading…
Reference in New Issue
Block a user