Skip to content

Forbid long symbol names staring with _ #3783

Description

@ShabbyX

ANGLE's shader translator prefixes symbol names with _u, but it can't do that if the symbol name is at least 1022 characters. To avoid name collisions, it has validation that if a name is at least 1022 characters and starts with _u, compilation fails.

A while ago, we made that u in _u configurable, which means the check is not correct if the compiler is invoked with anything other than u. I've also recently found a case where it makes sense to use different prefixes for different symbols, so the check would have to verify multiple prefixes, like _u, _b, etc.

I'd like to change the validation to forbid any too-long name that starts with _ like this. This requires changing the conformance2/glsl3/shader-with-1024-character-identifier.frag.html test because it does use a long name that starts with _a.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions