Skip to content
This repository was archived by the owner on Jun 20, 2025. It is now read-only.
This repository was archived by the owner on Jun 20, 2025. It is now read-only.

Add support for standard library types #120

@phan-do

Description

@phan-do

General

If you'd like to see a certain std type gain support in Getty, please leave a comment and I'll add it to the hit list.

Also, feel free to work on any of the types listed below. If you have any questions, you can ask them on our Discord or in this issue.

The Hit List

  • ArrayHashMap (includes Auto, String)
  • ArrayHashMapUnmanaged (includes Auto, String)
  • ArrayListAligned (includes ArrayList)
  • ArrayListAlignedUnmanaged (includes ArrayListUnmanaged)
  • IntegerBitSet (includes half of StaticBitSet)
  • ArrayBitSet (includes half of StaticBitSet)
  • DynamicBitSetUnmanaged
  • DynamicBitSet
  • BoundedArray
  • BufMap
  • BufSet
  • ComptimeStringMap
  • BoundedEnumMultiset (includes EnumMultiset)
  • IndexedArray (includes EnumArray)
  • IndexedSet
  • IndexedMap
  • LinearFifo
  • HashMap (includes Auto, String)
  • HashMapUnmanaged (includes Auto, String)
  • SinglyLinkedList
  • TailQueue
  • MultiArrayList
  • net.Address
    • Serialization support is done.
    • Deserialization support broke due to some memcpy issue in std net.zig:
      $ zig build test
      run deserialization test: error: thread 1007393 panic: @memcpy arguments alias
      /Users/jason/.asdf/installs/zig/master/lib/std/net.zig:553:70: 0x102138407 in resolve (deserialization test)
                  @memcpy(result.sa.addr[16 - index ..][0..index], ip_slice[0..index]);
                                                                           ^
      /Users/jason/.asdf/installs/zig/master/lib/std/net.zig:85:54: 0x102138dc7 in resolveIp6 (deserialization test)
              return Address{ .in6 = try Ip6Address.resolve(buf, port) };
                                                           ^
      /Users/jason/.asdf/installs/zig/master/lib/std/net.zig:58:23: 0x10213900f in resolveIp (deserialization test)
              if (resolveIp6(name, port)) |ip6| return ip6 else |err| switch (err) {
                            ^
      /Users/jason/Projects/Personal/getty/src/de/blocks/net_address.zig:63:50: 0x10213a413 in test.deserialize - std.net.Address (deserialization test)
                      .want = std.net.Address.resolveIp(ipv6, 0) catch return error.UnexpectedTestError,
                                                       ^
      /Users/jason/.asdf/installs/zig/master/lib/test_runner.zig:99:29: 0x1020cb44b in mainServer (deserialization test)
                      test_fn.func() catch |err| switch (err) {
                                  ^
      /Users/jason/.asdf/installs/zig/master/lib/test_runner.zig:33:26: 0x1020c4d57 in main (deserialization test)
              return mainServer() catch @panic("internal test runner failure");
                               ^
      /Users/jason/.asdf/installs/zig/master/lib/std/start.zig:598:22: 0x1020c48f7 in main (deserialization test)
                  root.main();
  • net.Ip4Address (?, might be covered by net.Address)
  • net.Ip6Address (?, might be covered by net.Address)
  • net.AddressList
  • PackedIntArrayEndian (includes PackedIntArray)
  • PackedIntSliceEndian (includes PackedIntSlice)
  • PriorityDequeue
  • PriorityQueue
  • SegmentedList
  • SemanticVersion
  • Uri

Metadata

Metadata

Assignees

No one assigned

    Labels

    acceptedThis proposal is planned.proposalThis issue suggests modifications. If it also has the "accepted" label then it is planned.

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions