brintos

brintos / llvm-project-archived public Read only

0
0
Text · 955 B · 532f1a1 Raw
25 lines · cpp
1// RUN: %clang_cc1 -std=c++98 %s -verify=expected -fexceptions -fcxx-exceptions -pedantic-errors2// RUN: %clang_cc1 -std=c++11 %s -verify=expected -fexceptions -fcxx-exceptions -pedantic-errors3// RUN: %clang_cc1 -std=c++14 %s -verify=expected -fexceptions -fcxx-exceptions -pedantic-errors4// RUN: %clang_cc1 -std=c++17 %s -verify=expected -fexceptions -fcxx-exceptions -pedantic-errors5// RUN: %clang_cc1 -std=c++20 %s -verify=expected -fexceptions -fcxx-exceptions -pedantic-errors6// RUN: %clang_cc1 -std=c++23 %s -verify=expected -fexceptions -fcxx-exceptions -pedantic-errors7// RUN: %clang_cc1 -std=c++2c %s -verify=expected -fexceptions -fcxx-exceptions -pedantic-errors8 9// expected-no-diagnostics10 11#include <stdarg.h>12#include <stddef.h>13namespace cwg273 { // cwg273: 2.714  struct A {15    int n;16  };17  void operator&(A);18  void f(A a, ...) {19    offsetof(A, n);20    va_list val;21    va_start(val, a);22    va_end(val);23  }24} // namespace cwg27325