Immutable expression issue

Dear all,

how can define immutable in Julia 1.1.0?

e.g.;


immutable MySingleton end ERROR: syntax: extra token "MySingleton" after end of expression

Best regards

1 Like

structs are immutable by default in v1.0+.

3 Likes

in Julia 1.0 …

how can we redefine:


immutable NeoHook{T}
    μ::T
    λ::T
end

thanks in advance

struct

2 Likes