# \#enum

**URL:** https://forums.swift.org/tag/enum/961.md

[Latest](https://forums.swift.org/latest.md) · [Categories](https://forums.swift.org/categories.md) · [Tags](https://forums.swift.org/tags.md)

---

## [Problem with enums in embedded swift](https://forums.swift.org/t/problem-with-enums-in-embedded-swift/85764)

<div class="topic-metadata">

**Author:** [@typoland](https://forums.swift.org/u/typoland)\
**Replies:** 20\
**Last updated:** [April 7, 2026, 10:46am UTC](https://forums.swift.org/t/problem-with-enums-in-embedded-swift/85764 "2026-04-07T10:46:01Z")

</div>

I play with pure bare metal example for esp32c6 Bare-Metal Swift on M5Stack NanoC6: No C, No Assembly, No ESP-IDF - #3 by trickart from @trickart I tried to make PWMLed and use enums: struct PWMLedOld { enum Timer: UI…

---

## [Attached macros on enum case declarations](https://forums.swift.org/t/attached-macros-on-enum-case-declarations/85024)

<div class="topic-metadata">

**Author:** [@Dan\_Stenmark](https://forums.swift.org/u/Dan_Stenmark)\
**Replies:** 4\
**Last updated:** [February 27, 2026, 4:49pm UTC](https://forums.swift.org/t/attached-macros-on-enum-case-declarations/85024 "2026-02-27T16:49:30Z")

</div>

I recently had a situation where being able to attach peer macros to enum case declarations would've been a boon towards removing custom initializers. Something like this: @APIResponsePayload enum MyResponsePayload { …
