1 // RUN: %clang_cc1 %s -verify -pedantic -fsyntax-only 2 3 constant sampler_t glb_smp = 5; 4 5 void foo(sampler_t); 6 7 void kernel ker(sampler_t argsmp) { 8 local sampler_t smp; // expected-error {{sampler type cannot be used with the __local and __global address space qualifiers}} 9 const sampler_t const_smp = 7; 10 foo(glb_smp); 11 foo(const_smp); 12 foo(5); // expected-error {{sampler_t variable required - got 'int'}} 13 } 14