1 // RUN: %clang_cc1 -triple dxil-pc-shadermodel6.0-compute -x hlsl -ast-dump -o - %s | FileCheck %s
\r
3 // CHECK: CXXRecordDecl 0x{{[0-9a-f]+}} {{.*}} struct MyBuffer definition
\r
4 // CHECK: FieldDecl 0x{{[0-9a-f]+}} <line:[[# @LINE + 4]]:3, col:68> col:68 h '__hlsl_resource_t
\r
5 // CHECK-SAME{LITERAL}: [[hlsl::resource_class(UAV)]]
\r
6 // CHECK-SAME{LITERAL}: [[hlsl::is_rov]]
\r
8 __hlsl_resource_t [[hlsl::resource_class(UAV)]] [[hlsl::is_rov]] h;
\r
11 // CHECK: VarDecl 0x{{[0-9a-f]+}} <line:[[# @LINE + 3]]:1, col:66> col:66 res '__hlsl_resource_t
\r
12 // CHECK-SAME{LITERAL}: [[hlsl::resource_class(SRV)]]
\r
13 // CHECK-SAME{LITERAL}: [[hlsl::is_rov]]
\r
14 __hlsl_resource_t [[hlsl::is_rov]] [[hlsl::resource_class(SRV)]] res;
\r
16 // CHECK: FunctionDecl 0x{{[0-9a-f]+}} <line:[[# @LINE + 4]]:1, line:[[# @LINE + 6]]:1> line:[[# @LINE + 4]]:6 f 'void ()
\r
17 // CHECK: VarDecl 0x{{[0-9a-f]+}} <col:3, col:72> col:72 r '__hlsl_resource_t
\r
18 // CHECK-SAME{LITERAL}: [[hlsl::resource_class(Sampler)]]
\r
19 // CHECK-SAME{LITERAL}: [[hlsl::is_rov]]
\r
21 __hlsl_resource_t [[hlsl::resource_class(Sampler)]] [[hlsl::is_rov]] r;
\r