jcrist / msgspec

A fast serialization and validation library, with builtin support for JSON, MessagePack, YAML, and TOML
https://jcristharif.com/msgspec/
BSD 3-Clause "New" or "Revised" License
2.44k stars 75 forks source link

can msgspec provide a faster enum implementation? #674

Open aspizu opened 7 months ago

aspizu commented 7 months ago

Description

if msgspec.Struct is faster than dataclasses, can msgspec also provide enums?

There is fastenum which claims to be faster than regular python enum. but its not written in C.

aspizu commented 7 months ago

also i would like if the api didn't require the usage of auto()