glsl icon indicating copy to clipboard operation
glsl copied to clipboard

GLSL parser for Rust

Results 28 glsl issues
Sort by recently updated
recently updated
newest added

* Precision and type are mangled together: `mediumpfloat` should be `mediump float` * Typo: "low" should be "lowp"

I realized some parsers expect `\n` as the single char for a line ending, which isn't the case on Windows with its notorious `\r\n`. This PR replaces occurrences of `\n`...

Both do-while statements and expression for-init statements would be output with incorrect syntax by `show_translation_unit`. This PR adds the missing semicolons as needed. Example Input: ```glsl do { a(); }...

According to [The OpenGL Shading Language 4.5 specification](https://www.khronos.org/registry/OpenGL/specs/gl/GLSLangSpec.4.50.pdf), § 3.3, page 13, `#elif` is the standards-compliant and recognized way to write an "else if" preprocessor directive, instead of the `#elseif`...

Parser cannot handle a case with function-like preprocessor being called without a semicolon, even if it's not technically required if proper preprocessor were run, because the semicolon is inside the...

object and function-like `#define`'s parsers are including newline character in parsed out value. The parser succeeds but the extra character in value can cause issues while transpiling.

Thanks so much for this crate @phaazon :) I was planning on using this along with a json crate to create a small lib for parsing ISF aka [Interactive Shader...

question & discussion

I just attempted to parse a large collection of test shaders, and they all worked beautifully, except one! Here's the culprit in its entirey: ```glsl /*{ "CATEGORIES": [ "Dissolve" ],...

Here's the error I'm hitting, which also shows the GLSL excerpt that triggers it: ``` error: proc macro panicked | 38 | let gtu = glsl! { | _______________^ 39...

a single call to blank_space() can end up heap allocating mutiple `VerboseError`s and since it shows up in lots of places we end up doing unnecessary allocations all over the...