class OMPArraySectionExpr

Declaration

class OMPArraySectionExpr : public Expr { /* full declaration omitted */ };

Description

OpenMP 5.0 [2.1.5, Array Sections]. To specify an array section in an OpenMP construct, array subscript expressions are extended with the following syntax: The array section must be a subset of the original array. Array sections are allowed on multidimensional arrays. Base language array subscript expressions can be used to specify length-one dimensions of multidimensional array sections. Each of the lower-bound, length, and stride expressions if specified must be an integral type expressions of the base language. When evaluated they represent a set of integer values as follows: The lower-bound and length must evaluate to non-negative integers. The stride must evaluate to a positive integer. When the size of the array dimension is not known, the length must be specified explicitly. When the stride is absent it defaults to 1. When the length is absent it defaults to ⌈(size − lower-bound)/stride⌉, where size is the size of the array dimension. When the lower-bound is absent it defaults to 0.

Declared at: clang/include/clang/AST/ExprOpenMP.h:56

Inherits from: Expr

Member Variables

private clang::Stmt* [4] SubExprs
private clang::SourceLocation ColonLocFirst
private clang::SourceLocation ColonLocSecond
private clang::SourceLocation RBracketLoc

Inherited from Stmt:

protected

Method Overview

Inherited from Expr:

Inherited from ValueStmt:

Inherited from Stmt:

Methods

OMPArraySectionExpr(clang::Stmt::EmptyShell Shell)

Description

Create an empty array section expression.

Declared at: clang/include/clang/AST/ExprOpenMP.h:79

Parameters

clang::Stmt::EmptyShell Shell

OMPArraySectionExpr(
    clang::Expr* Base,
    clang::Expr* LowerBound,
    clang::Expr* Length,
    clang::Expr* Stride,
    clang::QualType Type,
    clang::ExprValueKind VK,
    clang::ExprObjectKind OK,
    clang::SourceLocation ColonLocFirst,
    clang::SourceLocation ColonLocSecond,
    clang::SourceLocation RBracketLoc)

Declared at: clang/include/clang/AST/ExprOpenMP.h:64

Parameters

clang::Expr* Base
clang::Expr* LowerBound
clang::Expr* Length
clang::Expr* Stride
clang::QualType Type
clang::ExprValueKind VK
clang::ExprObjectKind OK
clang::SourceLocation ColonLocFirst
clang::SourceLocation ColonLocSecond
clang::SourceLocation RBracketLoc

clang::Stmt::const_child_range children() const

Declared at: clang/include/clang/AST/ExprOpenMP.h:139

clang::Stmt::child_range children()

Declared at: clang/include/clang/AST/ExprOpenMP.h:135

static bool classof(const clang::Stmt* T)

Declared at: clang/include/clang/AST/ExprOpenMP.h:131

Parameters

const clang::Stmt* T

clang::Expr* getBase()

Description

Get base of the array section.

Declared at: clang/include/clang/AST/ExprOpenMP.h:85

const clang::Expr* getBase() const

Declared at: clang/include/clang/AST/ExprOpenMP.h:86

static clang::QualType getBaseOriginalType(
    const clang::Expr* Base)

Description

Return original type of the base expression for array section.

Declared at: clang/include/clang/AST/ExprOpenMP.h:91

Parameters

const clang::Expr* Base

clang::SourceLocation getBeginLoc() const

Declared at: clang/include/clang/AST/ExprOpenMP.h:113

clang::SourceLocation getColonLocFirst() const

Declared at: clang/include/clang/AST/ExprOpenMP.h:118

clang::SourceLocation getColonLocSecond() const

Declared at: clang/include/clang/AST/ExprOpenMP.h:121

clang::SourceLocation getEndLoc() const

Declared at: clang/include/clang/AST/ExprOpenMP.h:116

clang::SourceLocation getExprLoc() const

Declared at: clang/include/clang/AST/ExprOpenMP.h:127

clang::Expr* getLength()

Description

Get length of array section.

Declared at: clang/include/clang/AST/ExprOpenMP.h:102

const clang::Expr* getLength() const

Declared at: clang/include/clang/AST/ExprOpenMP.h:103

const clang::Expr* getLowerBound() const

Declared at: clang/include/clang/AST/ExprOpenMP.h:95

clang::Expr* getLowerBound()

Description

Get lower bound of array section.

Declared at: clang/include/clang/AST/ExprOpenMP.h:94

clang::SourceLocation getRBracketLoc() const

Declared at: clang/include/clang/AST/ExprOpenMP.h:124

const clang::Expr* getStride() const

Declared at: clang/include/clang/AST/ExprOpenMP.h:109

clang::Expr* getStride()

Description

Get stride of array section.

Declared at: clang/include/clang/AST/ExprOpenMP.h:108

void setBase(clang::Expr* E)

Description

Set base of the array section.

Declared at: clang/include/clang/AST/ExprOpenMP.h:88

Parameters

clang::Expr* E

void setColonLocFirst(clang::SourceLocation L)

Declared at: clang/include/clang/AST/ExprOpenMP.h:119

Parameters

clang::SourceLocation L

void setColonLocSecond(clang::SourceLocation L)

Declared at: clang/include/clang/AST/ExprOpenMP.h:122

Parameters

clang::SourceLocation L

void setLength(clang::Expr* E)

Description

Set length of the array section.

Declared at: clang/include/clang/AST/ExprOpenMP.h:105

Parameters

clang::Expr* E

void setLowerBound(clang::Expr* E)

Description

Set lower bound of the array section.

Declared at: clang/include/clang/AST/ExprOpenMP.h:99

Parameters

clang::Expr* E

void setRBracketLoc(clang::SourceLocation L)

Declared at: clang/include/clang/AST/ExprOpenMP.h:125

Parameters

clang::SourceLocation L

void setStride(clang::Expr* E)

Description

Set length of the array section.

Declared at: clang/include/clang/AST/ExprOpenMP.h:111

Parameters

clang::Expr* E