Bitflags in API traces are hard to write and read #1195
Labels
area: infrastructure
Testing, building, coordinating issues
help required
We need community help to make this happen.
type: enhancement
New feature or request
Is your feature request related to a problem? Please describe.
When writing a playtest or reading an API trace, it's difficult to reason about bitflag values. See https://github.com/gfx-rs/wgpu/pull/1191/files#diff-78d438d1c2e726454851597e74ab167a9579d6cd83d7f712fcea59173cc2b274R27 for example.
Describe the solution you'd like
Something like https://github.com/kvark/bitflags-serial, where the flags are serialized as
VALUE | ANOTHER_VALUE
Another alternative is to turn them into structures like
Foo { bit_some: bool, bit_other: bool, ...}
, but that's more complicated.Describe alternatives you've considered
Keep them integers but comment on each use...
Additional context
See upstream in bitflags/bitflags#147
Is also a problem for gfx-rs Warden testing infra.
The text was updated successfully, but these errors were encountered: