class Collection

Defined at line 15 of file ../../src/developer/debug/zxdb/symbols/collection.h

Represents a C/C++ class, struct, or union, or a Rust enum (see the variant_part() member).

Public Methods

const char * CallingConventionToString (CallingConvention cc)

Defined at line 19 of file ../../src/developer/debug/zxdb/symbols/collection.cc

SpecialType GetSpecialType ()

Heuristic that attempts to determine whether this collection has special

meaning in the current programming language.

Defined at line 33 of file ../../src/developer/debug/zxdb/symbols/collection.cc

const char * GetKindString ()

Returns a pointer to either "struct", "class", or "union" depending on the

type of this object. This is useful for error messages.

Defined at line 39 of file ../../src/developer/debug/zxdb/symbols/collection.cc

const std::vector<LazySymbol> & data_members ()

Data members. These should be DataMember objects.

Defined at line 58 of file ../../src/developer/debug/zxdb/symbols/collection.h

void set_data_members (std::vector<LazySymbol> d)

Defined at line 59 of file ../../src/developer/debug/zxdb/symbols/collection.h

const LazySymbol & variant_part ()

This will be a VariantPart class if there is one defined.

Currently this is used only for Rust enums. In this case, the collection will contain one

VariantPart (the Variants inside of it will encode the enumerated possibilities) and this

collection will have no data_members() in its vector. See the VariantPart declaration for more

details.

Theoretically DWARF could encode more than one variant part child of a struct but none of our

supported compilers or languages do this so we save as a single value.

Defined at line 70 of file ../../src/developer/debug/zxdb/symbols/collection.h

void set_variant_part (const LazySymbol & vp)

Defined at line 71 of file ../../src/developer/debug/zxdb/symbols/collection.h

const std::vector<LazySymbol> & inherited_from ()

Classes/structs this one inherits from. This should be a InheritedFrom object.

These are in the same order as declared in the symbol file.

Defined at line 76 of file ../../src/developer/debug/zxdb/symbols/collection.h

void set_inherited_from (std::vector<LazySymbol> f)

Defined at line 77 of file ../../src/developer/debug/zxdb/symbols/collection.h

const std::vector<LazySymbol> & template_params ()

Template parameters if this collection is a template instantiation.

Defined at line 80 of file ../../src/developer/debug/zxdb/symbols/collection.h

void set_template_params (std::vector<LazySymbol> p)

Defined at line 81 of file ../../src/developer/debug/zxdb/symbols/collection.h

CallingConvention calling_convention ()

Defined at line 83 of file ../../src/developer/debug/zxdb/symbols/collection.h

void set_calling_convention (CallingConvention cc)

Defined at line 84 of file ../../src/developer/debug/zxdb/symbols/collection.h

Protected Methods

const Collection * AsCollection ()

Symbol protected overrides.

Defined at line 31 of file ../../src/developer/debug/zxdb/symbols/collection.cc

Enumerations

enum SpecialType
Name Value
kNotSpecial 0
kRustEnum 1
kRustTuple 2
kRustTupleStruct 3

Heuristically-derived special type of a collection.

Defined at line 20 of file ../../src/developer/debug/zxdb/symbols/collection.h

enum CallingConvention
Name Value
kNormalCall 1
kPassByReference 4
kPassByValue 5

The values are the DW_CC_* calling conventions from DWARF. The other values don't apply to

collections.

Defined at line 50 of file ../../src/developer/debug/zxdb/symbols/collection.h

Friends

class MakeRefCountedHelper
class RefCountedThreadSafe