mirror of
https://github.com/llvm/llvm-project.git
synced 2025-04-25 00:06:05 +00:00

Binary operators are also of struct type in C, when assigning. Don't try to get the ComparisonCategoryInfo in that case.
18 lines
289 B
C
18 lines
289 B
C
// RUN: %clang_cc1 -fsyntax-only %s -verify
|
|
// RUN: %clang_cc1 -fsyntax-only %s -fexperimental-new-constant-interpreter -verify
|
|
// expected-no-diagnostics
|
|
|
|
struct S {
|
|
int one;
|
|
int two;
|
|
};
|
|
|
|
struct S const foo(void);
|
|
|
|
|
|
struct S tmp;
|
|
|
|
void priv_sock_init(void) {
|
|
tmp = (struct S)foo();
|
|
}
|