Understanding Clojure's Persistent Vectors, pt. 1 (2013)

(hypirion.com)

29 pontos | por mirzap 4 dias atrás

1 comentários

  • goldfishgold
    4 horas atrás
    Scala has a similar data structure https://www.scala-lang.org/api/2.13.6/scala/collection/immut.... Something was in the air in 2013.
    • swannodette
      3 horas atrás
      Clarifying Clojure had them in 2007. Scala implementations were inspired by Clojure’s. Both Odersky and Bagwell have given credit to Hickey.
    • stingraycharles
      3 horas atrás
      It’s not a secret that they came from the same zeitgeist but took wildly different approaches, but inspired each other.

      I still don’t understand why they’re referred to as persistent vectors rather than immutable vectors, but I digress.

      • lemming
        3 horas atrás
        I still don’t understand why they’re referred to as persistent vectors rather than immutable vectors, but I digress.

        I believe that immutable just means, well, immutable, but persistent means that updates are achieved via structural sharing, so they’re efficient.