Skip to content

FedericoStra/RedefStructs.jl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

RedefStructs.jl

Lifecycle Stable Dev Build Status Code Style: Blue ColPrac: Contributor's Guide on Collaborative Practices for Community Packages

This package provides the macro @redef, which allows to create structures which are redefinable.

Example

julia> using RedefStructs

julia> @redef struct S
           s::String
       end

julia> S("Hello").s
"Hello"

julia> @redef mutable struct S
           n::Int
       end

julia> S(42).n
42