You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
actually given this is a parse error, it is probably necessary to go instead with
julia>@lazymutable struct A
const x::Intconst@lazy y::Intend
ERROR: LoadError: expected a @lazy field inside the struct
Stacktrace:
[1] error(s::String)
@ Base ./error.jl:35
[2] lazy_struct(expr::Expr, mod::Module)
@ LazilyInitializedFields ~/.julia/packages/LazilyInitializedFields/EAhdM/src/LazilyInitializedFields.jl:307
[3] var"@lazy"(__source__::LineNumberNode, __module__::Module, expr::Any)
@ LazilyInitializedFields ~/.julia/packages/LazilyInitializedFields/EAhdM/src/LazilyInitializedFields.jl:264
in expression starting at REPL[13]:1
This is useful when you don't really want to initialize always that field in all cases, but only for some instances, but if it is initiliazed to an actual value you want that it can't be changed (as in my case)
The text was updated successfully, but these errors were encountered:
It doesn't seem to work currently:
actually given this is a parse error, it is probably necessary to go instead with
This is useful when you don't really want to initialize always that field in all cases, but only for some instances, but if it is initiliazed to an actual value you want that it can't be changed (as in my case)
The text was updated successfully, but these errors were encountered: