v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
v8::internal::torque::StructType Class Referencefinal

#include <types.h>

Inheritance diagram for v8::internal::torque::StructType:
Collaboration diagram for v8::internal::torque::StructType:

Public Types

enum class  ClassificationFlag { kEmpty = 0 , kStrongTagged = 1 << 0 , kWeakTagged = 1 << 1 , kUntagged = 1 << 2 }
 
using Classification = base::Flags<ClassificationFlag>
 
- Public Types inherited from v8::internal::torque::Type
enum class  HandleKind { kIndirect , kDirect }
 
- Public Types inherited from v8::internal::torque::TypeBase
enum class  Kind {
  kTopType , kAbstractType , kBuiltinPointerType , kUnionType ,
  kBitFieldStructType , kStructType , kClassType
}
 

Public Member Functions

std::string GetGeneratedTypeNameImpl () const override
 
size_t PackedSize () const
 
size_t AlignmentLog2 () const override
 
Classification ClassifyContents () const
 
SourcePosition GetPosition () const
 
- Public Member Functions inherited from v8::internal::torque::AggregateType
std::string GetGeneratedTNodeTypeNameImpl () const override
 
void SetFields (std::vector< Field > fields)
 
const std::vector< Field > & fields () const
 
bool HasField (const std::string &name) const
 
const FieldLookupField (const std::string &name) const
 
const std::string & name () const
 
Namespacenspace () const
 
virtual const FieldRegisterField (Field field)
 
void RegisterMethod (Method *method)
 
const std::vector< Method * > & Methods () const
 
std::vector< Method * > Methods (const std::string &name) const
 
std::vector< const AggregateType * > GetHierarchy () const
 
std::vector< TypeCheckerGetTypeCheckers () const override
 
const FieldLastField () const
 
- Public Member Functions inherited from v8::internal::torque::Type
Typeoperator= (const Type &other)=delete
 
virtual bool IsSubtypeOf (const Type *supertype) const
 
std::string ToString () const
 
virtual std::string SimpleName () const
 
std::string GetHandleTypeName (HandleKind kind, const std::string &type_name) const
 
std::string TagglifiedCppTypeName () const
 
std::string HandlifiedCppTypeName (HandleKind kind) const
 
const Typeparent () const
 
bool IsVoid () const
 
bool IsNever () const
 
bool IsBool () const
 
bool IsConstexprBool () const
 
bool IsVoidOrNever () const
 
bool IsFloat32 () const
 
bool IsFloat64 () const
 
std::string GetGeneratedTypeName () const
 
std::string GetGeneratedTNodeTypeName () const
 
virtual bool IsConstexpr () const
 
virtual bool IsTransient () const
 
virtual const TypeNonConstexprVersion () const
 
virtual std::string GetConstexprGeneratedTypeName () const
 
std::optional< const ClassType * > ClassSupertype () const
 
std::optional< const StructType * > StructSupertype () const
 
std::optional< const AggregateType * > AggregateSupertype () const
 
virtual std::string GetRuntimeType () const
 
virtual std::string GetDebugType () const
 
void AddAlias (std::string alias) const
 
size_t id () const
 
const MaybeSpecializationKeyGetSpecializedFrom () const
 
virtual void SetConstexprVersion (const Type *type) const
 
virtual const TypeConstexprVersion () const
 
- Public Member Functions inherited from v8::internal::torque::TypeBase
virtual ~TypeBase ()=default
 
bool IsTopType () const
 
bool IsAbstractType () const
 
bool IsBuiltinPointerType () const
 
bool IsUnionType () const
 
bool IsBitFieldStructType () const
 
bool IsStructType () const
 
bool IsClassType () const
 
bool IsAggregateType () const
 

Private Member Functions

 StructType (Namespace *nspace, const StructDeclaration *decl, MaybeSpecializationKey specialized_from=std::nullopt)
 
void Finalize () const override
 
std::string ToExplicitString () const override
 
std::string SimpleNameImpl () const override
 

Private Attributes

const StructDeclarationdecl_
 
std::string generated_type_name_
 

Friends

class TypeOracle
 

Additional Inherited Members

- Static Public Member Functions inherited from v8::internal::torque::Type
static const TypeCommonSupertype (const Type *a, const Type *b)
 
static std::optional< const Type * > MatchUnaryGeneric (const Type *type, GenericType *generic)
 
static std::string ComputeName (const std::string &basename, MaybeSpecializationKey specialized_from)
 
- Protected Member Functions inherited from v8::internal::torque::AggregateType
 AggregateType (Kind kind, const Type *parent, Namespace *nspace, const std::string &name, MaybeSpecializationKey specialized_from=std::nullopt)
 
void CheckForDuplicateFields () const
 
const FieldLookupFieldInternal (const std::string &name) const
 
- Protected Member Functions inherited from v8::internal::torque::Type
 Type (TypeBase::Kind kind, const Type *parent, MaybeSpecializationKey specialized_from=std::nullopt)
 
 Type (const Type &other) V8_NOEXCEPT
 
void set_parent (const Type *t)
 
int Depth () const
 
- Protected Member Functions inherited from v8::internal::torque::TypeBase
 TypeBase (Kind kind)
 
Kind kind () const
 
- Protected Attributes inherited from v8::internal::torque::AggregateType
bool is_finalized_
 
std::vector< Fieldfields_
 

Detailed Description

Definition at line 616 of file types.h.

Member Typedef Documentation

◆ Classification

Member Enumeration Documentation

◆ ClassificationFlag

Enumerator
kEmpty 
kStrongTagged 
kWeakTagged 
kUntagged 

Definition at line 627 of file types.h.

Constructor & Destructor Documentation

◆ StructType()

v8::internal::torque::StructType::StructType ( Namespace * nspace,
const StructDeclaration * decl,
MaybeSpecializationKey specialized_from = std::nullopt )
private

Definition at line 504 of file types.cc.

Member Function Documentation

◆ AlignmentLog2()

size_t v8::internal::torque::StructType::AlignmentLog2 ( ) const
overridevirtual

Reimplemented from v8::internal::torque::Type.

Definition at line 1305 of file types.cc.

Here is the call graph for this function:

◆ ClassifyContents()

StructType::Classification v8::internal::torque::StructType::ClassifyContents ( ) const

Definition at line 529 of file types.cc.

Here is the call graph for this function:

◆ Finalize()

void v8::internal::torque::StructType::Finalize ( ) const
overrideprivatevirtual

Implements v8::internal::torque::AggregateType.

Definition at line 601 of file types.cc.

Here is the call graph for this function:

◆ GetGeneratedTypeNameImpl()

std::string v8::internal::torque::StructType::GetGeneratedTypeNameImpl ( ) const
overridevirtual

Reimplemented from v8::internal::torque::AggregateType.

Definition at line 517 of file types.cc.

Here is the caller graph for this function:

◆ GetPosition()

SourcePosition v8::internal::torque::StructType::GetPosition ( ) const
inline

Definition at line 638 of file types.h.

◆ PackedSize()

size_t v8::internal::torque::StructType::PackedSize ( ) const

Definition at line 521 of file types.cc.

Here is the call graph for this function:

◆ SimpleNameImpl()

std::string v8::internal::torque::StructType::SimpleNameImpl ( ) const
overrideprivatevirtual

Reimplemented from v8::internal::torque::AggregateType.

Definition at line 570 of file types.cc.

◆ ToExplicitString()

std::string v8::internal::torque::StructType::ToExplicitString ( ) const
overrideprivatevirtual

Implements v8::internal::torque::Type.

Definition at line 599 of file types.cc.

Here is the call graph for this function:

Friends And Related Symbol Documentation

◆ TypeOracle

friend class TypeOracle
friend

Definition at line 641 of file types.h.

Member Data Documentation

◆ decl_

const StructDeclaration* v8::internal::torque::StructType::decl_
private

Definition at line 649 of file types.h.

◆ generated_type_name_

std::string v8::internal::torque::StructType::generated_type_name_
private

Definition at line 650 of file types.h.


The documentation for this class was generated from the following files: