dawn-cmake/src/validator
Ben Clayton ca2c1ed370 Validate that runtime arrays aren't used as parameters
Remove the logic around `arrayLength()` being passed anything but a member accessor. Runtime arrays types cannot be used for variables nor parameters.

Add validator logic and test for runtime array parameters.

Adjust the validator error message so it doesn't include the field / variable name. This read weird, and the same information is already provided by the source.

Bug: tint:266
Bug: tint:252
Change-Id: Iecedb0524e10a67b4f8ad15635d67fe61e9d69d9
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/36420
Auto-Submit: Ben Clayton <bclayton@google.com>
Commit-Queue: dan sinclair <dsinclair@chromium.org>
Reviewed-by: dan sinclair <dsinclair@chromium.org>
2021-01-05 18:20:40 +00:00
..
validator.cc validator: Migrate to using diagnostics 2020-11-26 16:50:02 +00:00
validator.h validator: Migrate to using diagnostics 2020-11-26 16:50:02 +00:00
validator_control_block_test.cc cleanup: Refactor tests to use ast::Builder helpers 2021-01-05 15:44:39 +00:00
validator_function_test.cc Add helper for function creation. 2020-12-16 15:15:40 +00:00
validator_impl.cc Validate that runtime arrays aren't used as parameters 2021-01-05 18:20:40 +00:00
validator_impl.h Validate that runtime arrays aren't used as parameters 2021-01-05 18:20:40 +00:00
validator_test.cc cleanup: Refactor tests to use ast::Builder helpers 2021-01-05 15:44:39 +00:00
validator_test_helper.cc Start cleaning up tests (4/N) 2020-12-15 14:10:28 +00:00
validator_test_helper.h Start cleaning up tests (4/N) 2020-12-15 14:10:28 +00:00
validator_type_test.cc Validate that runtime arrays aren't used as parameters 2021-01-05 18:20:40 +00:00