struct MaybeAlign

Declaration

struct MaybeAlign : public Optional { /* full declaration omitted */ };

Description

This struct is a compact representation of a valid (power of two) or undefined (0) alignment.

Declared at: llvm/include/llvm/Support/Alignment.h:117

Inherits from: Optional

Method Overview

Methods

MaybeAlign()

Description

Default is undefined.

Declared at: llvm/include/llvm/Support/Alignment.h:123

MaybeAlign(const llvm::MaybeAlign& Other)

Description

Do not perform checks in case of copy/move construct/assign, because the checks have been performed when building `Other`.

Declared at: llvm/include/llvm/Support/Alignment.h:126

Parameters

const llvm::MaybeAlign& Other

MaybeAlign(llvm::MaybeAlign&& Other)

Declared at: llvm/include/llvm/Support/Alignment.h:128

Parameters

llvm::MaybeAlign&& Other

MaybeAlign(uint64_t Value)

Declared at: llvm/include/llvm/Support/Alignment.h:134

Parameters

uint64_t Value

llvm::Align valueOrOne() const

Description

For convenience, returns a valid alignment or 1 if undefined.

Declared at: llvm/include/llvm/Support/Alignment.h:142