aboutsummaryrefslogtreecommitdiff
path: root/clang/test/SemaOpenCL/builtins-amdgcn-cvt-off-f32-i4-err.cl
blob: 30ffbfc130a94c74cadd46fc60adf6e5bf2523d5 (plain)
1
2
3
4
5
6
7
8
// RUN: %clang_cc1 -triple amdgcn-- -verify -S -o - %s

void test_builtin_amdgcn_cvt_off_f32_i4(int n) {
    struct A{ unsigned x; } a;
    __builtin_amdgcn_cvt_off_f32_i4(n, n); // expected-error {{too many arguments to function call, expected 1, have 2}}
    __builtin_amdgcn_cvt_off_f32_i4(); // expected-error {{too few arguments to function call, expected 1, have 0}}
    __builtin_amdgcn_cvt_off_f32_i4(a); // expected-error {{passing '__private struct A' to parameter of incompatible type 'int'}}
}