Files
derek.holloway 7502bf64a4
CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
Flatten subprojects into a single base monorepo
2026-09-02 16:34:47 -07:00

226 lines
7.5 KiB
C++

// RUN: rm -rf %t
// RUN: %clang_cc1 -extract-api --pretty-sgf --emit-sgf-symbol-labels-for-testing \
// RUN: -triple arm64-apple-macosx -x c++-header %s -o %t/output.symbols.json -verify
class Foo {
// RUN: FileCheck %s --input-file %t/output.symbols.json --check-prefix GETCOUNT
int getCount();
// GETCOUNT: "!testRelLabel": "memberOf $ c:@S@Foo@F@getCount# $ c:@S@Foo"
// GETCOUNT-LABEL: "!testLabel": "c:@S@Foo@F@getCount#"
// GETCOUNT: "accessLevel": "private",
// GETCOUNT: "declarationFragments": [
// GETCOUNT-NEXT: {
// GETCOUNT-NEXT: "kind": "typeIdentifier",
// GETCOUNT-NEXT: "preciseIdentifier": "c:I",
// GETCOUNT-NEXT: "spelling": "int"
// GETCOUNT-NEXT: },
// GETCOUNT-NEXT: {
// GETCOUNT-NEXT: "kind": "text",
// GETCOUNT-NEXT: "spelling": " "
// GETCOUNT-NEXT: },
// GETCOUNT-NEXT: {
// GETCOUNT-NEXT: "kind": "identifier",
// GETCOUNT-NEXT: "spelling": "getCount"
// GETCOUNT-NEXT: },
// GETCOUNT-NEXT: {
// GETCOUNT-NEXT: "kind": "text",
// GETCOUNT-NEXT: "spelling": "();"
// GETCOUNT-NEXT: }
// GETCOUNT-NEXT: ],
// GETCOUNT: "functionSignature": {
// GETCOUNT-NEXT: "returns": [
// GETCOUNT-NEXT: {
// GETCOUNT-NEXT: "kind": "typeIdentifier",
// GETCOUNT-NEXT: "preciseIdentifier": "c:I",
// GETCOUNT-NEXT: "spelling": "int"
// GETCOUNT-NEXT: }
// GETCOUNT-NEXT: ]
// GETCOUNT-NEXT: },
// GETCOUNT: "displayName": "Instance Method",
// GETCOUNT-NEXT: "identifier": "c++.method"
// GETCOUNT: "title": "getCount"
// GETCOUNT: "pathComponents": [
// GETCOUNT-NEXT: "Foo",
// GETCOUNT-NEXT: "getCount"
// GETCOUNT-NEXT: ]
// RUN: FileCheck %s --input-file %t/output.symbols.json --check-prefix SETL
virtual void setLength(int length) noexcept;
// SETL: "!testRelLabel": "memberOf $ c:@S@Foo@F@setLength#I# $ c:@S@Foo"
// SETL-LABEL: "!testLabel": "c:@S@Foo@F@setLength#I#"
// SETL: "declarationFragments": [
// SETL-NEXT: {
// SETL-NEXT: "kind": "keyword",
// SETL-NEXT: "spelling": "virtual"
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "text",
// SETL-NEXT: "spelling": " "
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "typeIdentifier",
// SETL-NEXT: "preciseIdentifier": "c:v",
// SETL-NEXT: "spelling": "void"
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "text",
// SETL-NEXT: "spelling": " "
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "identifier",
// SETL-NEXT: "spelling": "setLength"
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "text",
// SETL-NEXT: "spelling": "("
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "typeIdentifier",
// SETL-NEXT: "preciseIdentifier": "c:I",
// SETL-NEXT: "spelling": "int"
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "text",
// SETL-NEXT: "spelling": " "
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "internalParam",
// SETL-NEXT: "spelling": "length"
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "text",
// SETL-NEXT: "spelling": ") "
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "keyword",
// SETL-NEXT: "spelling": "noexcept"
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "text",
// SETL-NEXT: "spelling": ";"
// SETL-NEXT: }
// SETL-NEXT: ],
// SETL: "functionSignature": {
// SETL-NEXT: "parameters": [
// SETL-NEXT: {
// SETL-NEXT: "declarationFragments": [
// SETL-NEXT: {
// SETL-NEXT: "kind": "typeIdentifier",
// SETL-NEXT: "preciseIdentifier": "c:I",
// SETL-NEXT: "spelling": "int"
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "text",
// SETL-NEXT: "spelling": " "
// SETL-NEXT: },
// SETL-NEXT: {
// SETL-NEXT: "kind": "internalParam",
// SETL-NEXT: "spelling": "length"
// SETL-NEXT: }
// SETL-NEXT: ],
// SETL-NEXT: "name": "length"
// SETL-NEXT: }
// SETL-NEXT: ],
// SETL-NEXT: "returns": [
// SETL-NEXT: {
// SETL-NEXT: "kind": "typeIdentifier",
// SETL-NEXT: "preciseIdentifier": "c:v",
// SETL-NEXT: "spelling": "void"
// SETL-NEXT: }
// SETL-NEXT: ]
// SETL-NEXT: },
public:
// RUN: FileCheck %s --input-file %t/output.symbols.json --check-prefix GETFOO
static double getFoo();
// GETFOO: "!testRelLabel": "memberOf $ c:@S@Foo@F@getFoo#S $ c:@S@Foo"
// GETFOO-LABEL: "!testLabel": "c:@S@Foo@F@getFoo#S"
// GETFOO: "accessLevel": "public",
// GETFOO: "declarationFragments": [
// GETFOO-NEXT: {
// GETFOO-NEXT: "kind": "keyword",
// GETFOO-NEXT: "spelling": "static"
// GETFOO-NEXT: },
// GETFOO-NEXT: {
// GETFOO-NEXT: "kind": "text",
// GETFOO-NEXT: "spelling": " "
// GETFOO-NEXT: },
// GETFOO-NEXT: {
// GETFOO-NEXT: "kind": "typeIdentifier",
// GETFOO-NEXT: "preciseIdentifier": "c:d",
// GETFOO-NEXT: "spelling": "double"
// GETFOO-NEXT: },
// GETFOO-NEXT: {
// GETFOO-NEXT: "kind": "text",
// GETFOO-NEXT: "spelling": " "
// GETFOO-NEXT: },
// GETFOO-NEXT: {
// GETFOO-NEXT: "kind": "identifier",
// GETFOO-NEXT: "spelling": "getFoo"
// GETFOO-NEXT: },
// GETFOO-NEXT: {
// GETFOO-NEXT: "kind": "text",
// GETFOO-NEXT: "spelling": "();"
// GETFOO-NEXT: }
// GETFOO-NEXT: ],
// GETFOO: "functionSignature": {
// GETFOO-NEXT: "returns": [
// GETFOO-NEXT: {
// GETFOO-NEXT: "kind": "typeIdentifier",
// GETFOO-NEXT: "preciseIdentifier": "c:d",
// GETFOO-NEXT: "spelling": "double"
// GETFOO-NEXT: }
// GETFOO-NEXT: ]
// GETFOO-NEXT: },
// GETFOO: "kind": {
// GETFOO-NEXT: "displayName": "Static Method",
// GETFOO-NEXT: "identifier": "c++.type.method"
// GETFOO-NEXT: },
protected:
// RUN: FileCheck %s --input-file %t/output.symbols.json --check-prefix GETBAR
constexpr int getBar() const;
// GETBAR: "!testRelLabel": "memberOf $ c:@S@Foo@F@getBar#1 $ c:@S@Foo"
// GETBAR-LABEL: "!testLabel": "c:@S@Foo@F@getBar#1"
// GETBAR: "accessLevel": "protected"
// GETBAR: "declarationFragments": [
// GETBAR-NEXT: {
// GETBAR-NEXT: "kind": "keyword",
// GETBAR-NEXT: "spelling": "constexpr"
// GETBAR-NEXT: },
// GETBAR-NEXT: {
// GETBAR-NEXT: "kind": "text",
// GETBAR-NEXT: "spelling": " "
// GETBAR-NEXT: },
// GETBAR-NEXT: {
// GETBAR-NEXT: "kind": "typeIdentifier",
// GETBAR-NEXT: "preciseIdentifier": "c:I",
// GETBAR-NEXT: "spelling": "int"
// GETBAR-NEXT: },
// GETBAR-NEXT: {
// GETBAR-NEXT: "kind": "text",
// GETBAR-NEXT: "spelling": " "
// GETBAR-NEXT: },
// GETBAR-NEXT: {
// GETBAR-NEXT: "kind": "identifier",
// GETBAR-NEXT: "spelling": "getBar"
// GETBAR-NEXT: },
// GETBAR-NEXT: {
// GETBAR-NEXT: "kind": "text",
// GETBAR-NEXT: "spelling": "() "
// GETBAR-NEXT: },
// GETBAR-NEXT: {
// GETBAR-NEXT: "kind": "keyword",
// GETBAR-NEXT: "spelling": "const"
// GETBAR-NEXT: },
// GETBAR-NEXT: {
// GETBAR-NEXT: "kind": "text",
// GETBAR-NEXT: "spelling": ";"
// GETBAR-NEXT: }
// GETBAR-NEXT: ],
};
// expected-no-diagnostics