JanetDocsI'm feeling luckyGithub sign in

freeze



    function
    boot.janet on line 1877, column 1

    (freeze x)
    
    Freeze an object (make it immutable) and do a deep copy, making child
    values also immutable. Closures, fibers, and abstract types will not be
    recursively frozen, but all other types will.


1 exampleSign in to add an example
Loading...
(freeze @{:a @[1 2] 
          :b @{:x @[8 9] 
               :y :smile}})
# => {:a (1 2) :b {:x (8 9) :y :smile}}
sogaiu