Debian Codegraph @

clang/test/AST/ast-dump-riscv-attributes.cpp

raw
1 // RUN: %clang_cc1 -triple riscv64 -ast-dump -ast-dump-filter c23 -std=c23 -x c %s | FileCheck --strict-whitespace %s
2
3 // CHECK: FunctionDecl{{.*}}pre_c23
4 // CHECK-NEXT: |-CompoundStmt
5 // CHECK-NEXT: `-RISCVInterruptAttr{{.*}}supervisor
6 __attribute__((interrupt("supervisor"))) void pre_c23(){}
7
8 // CHECK: FunctionDecl{{.*}}in_c23
9 // CHECK-NEXT: |-CompoundStmt
10 // CHECK-NEXT: `-RISCVInterruptAttr{{.*}}supervisor
11 // CHECK-NOT: `-RISCVInterruptAttr{{.*}}machine
12 [[gnu::interrupt("supervisor")]] void in_c23(){}