coarray_index¶
One coindex of a coarray reference.
Declaration¶
Syntax¶
coarray_index = (expr? index, codimension_type star)
Arguments¶
Argument |
Description |
|---|---|
|
the image index. |
|
whether the coindex was written as |
Return values¶
None.
Description¶
The coindices in a[2] select the image, and are kept apart from the
subscripts that select an element within one image’s copy.
Examples¶
(coarray_index
:index (IntegerConstant
:n 1
:type (Integer
:kind 4
)
:intboz_type :Decimal
)
:star :CodimensionExpr
)
It comes from this complete ASR text document:
(TranslationUnit
:symtab (SymbolTable
:id 0
:symbols {
"main" (Program
:symtab (SymbolTable
:id 1
:symbols {
"a" (Variable
:parent_symtab 1
:name "a"
:dependencies []
:intent :Local
:symbolic_value nil
:value nil
:storage :Default
:type (Integer
:kind 4
)
:type_declaration nil
:abi :Source
:access :Public
:presence :Required
:value_attr false
:target_attr false
:contiguous_attr false
:bindc_name nil
:is_volatile false
:is_protected false
:pass_attr :NotMethod
:self_argument nil
:codims [
(codimension
:start (IntegerConstant
:n 1
:type (Integer
:kind 4
)
:intboz_type :Decimal
)
:end nil
:end_star :CodimensionExpr
)
]
)
"i" (Variable
:parent_symtab 1
:name "i"
:dependencies []
:intent :Local
:symbolic_value nil
:value nil
:storage :Default
:type (Integer
:kind 4
)
:type_declaration nil
:abi :Source
:access :Public
:presence :Required
:value_attr false
:target_attr false
:contiguous_attr false
:bindc_name nil
:is_volatile false
:is_protected false
:pass_attr :NotMethod
:self_argument nil
:codims []
)
}
)
:name "main"
:dependencies []
:body [
(Assignment
:target (Var
:v (SymbolRef 1 "i")
)
:value (CoarrayRef
:var (Var
:v (SymbolRef 1 "a")
)
:coindices [
(coarray_index
:index (IntegerConstant
:n 1
:type (Integer
:kind 4
)
:intboz_type :Decimal
)
:star :CodimensionExpr
)
]
:type (Integer
:kind 4
)
:value nil
)
:overloaded nil
:realloc_lhs false
:move_allocation false
)
]
)
}
)
:items []
)