mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-10-24 02:35:52 +00:00
And force shader code to always use LF endings.
Post merge, there were a number of files that crept in with CRLF endings.
Some Tint end-to-end tests take objection to CRLF endings.
CRLF endings can be detected with:
```
git grep -I --files-with-matches --perl-regexp '\r' HEAD
```
And fixed with:
```
find . -type f -exec dos2unix {} \;
```
Bug: dawn:1339
Change-Id: Iee054bafd15875de744b86e28393cd8229bd3cfa
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/86140
Kokoro-Run: Ben Clayton <bclayton@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
Commit-Queue: Ben Clayton <bclayton@google.com>
21 lines
339 B
WebGPU Shading Language
21 lines
339 B
WebGPU Shading Language
@stage(compute) @workgroup_size(1)
|
|
fn f() {
|
|
var i : i32;
|
|
var result : i32;
|
|
switch(i) {
|
|
case 0: {
|
|
result = 10;
|
|
}
|
|
case 1: {
|
|
result = 22;
|
|
}
|
|
case 2: {
|
|
result = 33;
|
|
}
|
|
default: {
|
|
result = 44;
|
|
break;
|
|
}
|
|
}
|
|
}
|