# Decoding a dictionary with a custom type (not String) as key

**URL:** <https://forums.swift.org/t/decoding-a-dictionary-with-a-custom-type-not-string-as-key/35290>\
**Category:** Using Swift\
**Tags:** codable, dictionary\
**Created:** [April 11, 2020, 6:19pm UTC](https://forums.swift.org/t/decoding-a-dictionary-with-a-custom-type-not-string-as-key/35290 "2020-04-11T18:19:17Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![itaiferber](https://sea2.discourse-cdn.com/swift/user_avatar/forums.swift.org/itaiferber/32/33840_2.png) [@itaiferber](https://forums.swift.org/u/itaiferber)\
**Post date:** [April 11, 2020, 8:58pm UTC](https://forums.swift.org/t/decoding-a-dictionary-with-a-custom-type-not-string-as-key/35290/5 "2020-04-11T20:58:23Z")

</div>

See also the discussion in [Bug or PEBKAC?](https://forums.swift.org/t/bug-or-pebkac/33796) (and [my response in the thread](https://forums.swift.org/t/bug-or-pebkac/33796/17) for some background on why this is the case).

---

_[View the full topic](https://forums.swift.org/t/decoding-a-dictionary-with-a-custom-type-not-string-as-key/35290)._
