Proof of concept for "span" feature, with WGSL & GLSL parsing augmented. (#1092)
* Proof of concept for "span" feature, with WGSL parsing augmented. * Review: 1) add_span was actually a bad idea, make it set_span and add set_span_if_unknown too. 2) panics on getting/setting span for invalid handles. 3) only set span for constants with a name 4) don't overwrite spans for types. * Added spans to blocks & more expressions getting spans in frontends. Definitely the shotgunny type of commit, but what can you do. The design I went with made spans mandatory to specify, so I had to go and wire them through wherever I could. * Moved Block to a separate module, +clippy * More spans for types in GLSL. * Remove pointless body method. * Make Arena interface require spans. Another shotgun commit, oh boy... * Fix tests. My loathsome habit to "quickly fix things along the way" made a lot of extra work for me here, having to fix my "fixes" for WGSL parser. * Rustfmt + clippy. * Fix compile-errors with span feature enabled. * Nuked set_span* from orbit. Deleting code feels great! * Code review - move feature flags inside functions. * Fix build with "deserialize" feature enabled.
parent
e2fc7ffd
Please register or sign in to comment