Typeify ColorAttachmentIndex

Also moves BindingNumber, BindGroupIndex, and BindingIndex to
IntegerTypes.h. Future TypedIntegers should be declared here.

Bug: dawn:442
Change-Id: I5ba8de3412fb48b7957b67e7c413a5097f8ec00f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/27880
Reviewed-by: Austin Eng <enga@chromium.org>
Commit-Queue: Austin Eng <enga@chromium.org>
This commit is contained in:
Austin Eng
2020-09-09 00:08:38 +00:00
committed by Commit Bot service account
parent 22e5e179fa
commit 7b7e098b11
28 changed files with 208 additions and 128 deletions

View File

@@ -99,11 +99,10 @@ TEST_F(ShaderModuleValidationTest, FragmentOutputLocationExceedsMaxColorAttachme
std::ostringstream stream;
stream << R"(#version 450
layout(location = )"
<< kMaxColorAttachments << R"() out vec4 fragColor;
<< static_cast<unsigned>(kMaxColorAttachments) << R"() out vec4 fragColor;
void main() {
fragColor = vec4(0.0, 1.0, 0.0, 1.0);
})";
ASSERT_DEVICE_ERROR(utils::CreateShaderModule(device, utils::SingleShaderStage::Fragment,
stream.str().c_str()));
}