To: J3 J3/23-170 From: John Reid & Reinhold Bader Subject: Interp for MOVE_ALLOC Date: 2023-June-10 ---------------------------------------------------------------------- NUMBER: Fxx/xxx TITLE: MOVE_ALLOC is insufficiently specified KEYWORDS: MOVE_ALLOC, coarray DEFECT TYPE: Erratum STATUS: J3 consideration in progress REFERENCES: N2213 (FDIS) INTRODUCTION It appears that MOVE_ALLOC is insufficiently specified for arguments that are coarrays or have coarray subobjects. The latter is a consequence of the fact that the base object is permitted to be allocatable in Fortran 2023. QUESTION 1: If FROM is a coarray, is it required that all images of the team have corresponding coarrays? QUESTION 2: If TO is an allocated coarray, is it required that all images of the team have corresponding coarrays? QUESTION 3: If FROM is of a type with a potential coarray subobject, was it intended thatMOVE_ALLOC be applicable to it? ANSWER 1: Yes, this is required because FROM becomes deallocated (even though the memory it referred to continues to exist). An edit is supplied. ANSWER 2: Yes, this is required because TO is deallocated in this case. An edit is supplied. ANSWER 3 - Alternative 1 No, it was not intended that MOVE_ALLOC be applicable to such objects. An edit is supplied to prevent such usage. ANSWER 3 - Alternative 2 Yes, it was intended that MOVE_ALLOC can be applied to such objects. However, the side effects of extending the coarray facilities to allocatable objects with coarray subobjects were overlooked. Edits are supplied to account for this case. EDITS to N2213: Question 1 In 16.9.147 MOVE_ALLOC, at the end of the para labelled FROM, add "If it is a coarray, all images of the current team shall have corresponding coarrays." Question 2 In 16.9.147 MOVE_ALLOC, at the end of the para labelled TO, add "If it is an allocated coarray, all images of the current team shall have corresponding coarrays." Question 3, Alternative 1 In 16.9.147 MOVE_ALLOC, in the para labelled FROM, after "may be of any type, rank, and corank." add "It shall not be of a type with a potential coarray subobject component". Question 3, Alternative 2 In 16.9.147 MOVE_ALLOC, at the end of the para labelled FROM, add "If it is an object with an allocated potential coarray subobject component, that subobject shall correspond on all images of the current team." In 16.9.147 MOVE_ALLOC, at the end of the para labelled TO, add "If it is an object with an allocated potential coarray subobject component, that subobject shall correspond on all images of the current team." In 16.9.147 MOVE_ALLOC, in the para dealing with the coarray case, after "When a reference to MOVE_ALLOC is executed for which the FROM argument is a coarray" add " or of a type with a potential coarray subobject component". SUBMITTED BY: John Reid & Reinhold Bader HISTORY: 23-xxx m230 Submitted ----------------------------------------------------------------------