Overview of Dict, Variant and Optional in MojoðŸ”Ĩ

āđāļŠāļĢāđŒ
āļāļąāļ‡
  • āđ€āļœāļĒāđāļžāļĢāđˆāđ€āļĄāļ·āđˆāļ­ 10 āļĄ.āļ„. 2025

āļ„āļ§āļēāļĄāļ„āļīāļ”āđ€āļŦāđ‡āļ™ • 5

  • @aethermass
    @aethermass 11 āļŦāļĨāļēāļĒāđ€āļ”āļ·āļ­āļ™āļāđˆāļ­āļ™ +3

    Is a String ever not a StringKey? Seems like the base String class should just implement the interface for StringKey. The current implementation seems to handle this with a conversion. Does that have a performance impact opposed to making the base String class implement the methods from StringKey?

    • @JC-tr2kw
      @JC-tr2kw 9 āļŦāļĨāļēāļĒāđ€āļ”āļ·āļ­āļ™āļāđˆāļ­āļ™

      @aethermass this seems already implemented for String / StringLiteral -> Implemented traits:
      AnyType, Boolable, CollectionElement, Copyable, EqualityComparable, Hashable, IntableRaising, KeyElement, Movable, Sized, Stringable

  • @StefanUytterhoeven
    @StefanUytterhoeven 8 āļŦāļĨāļēāļĒāđ€āļ”āļ·āļ­āļ™āļāđˆāļ­āļ™

    No dict copy?

  • @StefanUytterhoeven
    @StefanUytterhoeven 10 āļŦāļĨāļēāļĒāđ€āļ”āļ·āļ­āļ™āļāđˆāļ­āļ™ +2

    Dict is very very slow. Way much slower than in python!