MCPcopy Index your code
hub / github.com/msgspec/msgspec / EncoderStruct

Class EncoderStruct

tests/unit/test_struct_meta.py:343–346  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

341
342 # Use the custom metaclass to create a struct class
343 class EncoderStruct(metaclass=EncoderMeta):
344 id: int
345 name: str
346 tags: list[str] = []
347
348 # Create an instance
349 obj = EncoderStruct(id=123, name="test")

Calls

no outgoing calls

Tested by 1

Used in the wild real call sites across dependent graphs

searching dependent graphs…