FLANG
Public Attributes | List of all members
fir::factory::MutableBoxReallocation Struct Reference

#include <flang/Optimizer/Builder/MutableBox.h>

Public Attributes

fir::ExtendedValue newValue
 
mlir::Value oldAddress
 
mlir::Value wasReallocated
 
mlir::Value oldAddressWasAllocated
 

Detailed Description

Generate code to conditionally reallocate a MutableBoxValue with a new shape, lower bounds, and LEN parameters if it is unallocated or if its current shape or deferred LEN parameters do not match the provided ones. Lower bounds are only used if the entity needs to be allocated, otherwise, the MutableBoxValue will keep its current lower bounds. If the MutableBoxValue is an array, the provided shape can be empty, in which case the MutableBoxValue must already be allocated at runtime and its shape and lower bounds will be kept. If shape is empty, only a LEN parameter mismatch can trigger a reallocation. See Fortran 10.2.1.3 point 3 that this function is implementing for more details. The polymorphic requirements are not yet covered by this function.


The documentation for this struct was generated from the following file: