An even better approach is to have a proc macro that parses wgsl and writes the rust struct definitions for you. That way this failure case can't happen.
xyzsparetimexyz · · focus · HN ↗