20 July 2000  Page 1 of 1  J3/00-252

Subject: Minor specification change – accessibility of constructor in the presence of private

components

From: Van Snyder References: 00-251

1 Introduction – Specification

The restriction that a derived type constructor is not accessible if any components of the type are private is too strong. It is a holdover from Fortran 95, wherein all of the components were private, or none were. This paper advocates to make the constructor accessible, even if some components are private, and to prohibit providing a value for any private component. This allows to construct values for types that have private components so long as default initialization is provided for all private components. This paper depends on the term “directly corresponds”, developed in paper 00-251. Without that paper, that term would need to be developed here.

2 Edits

Edits refer to 00-007r2. Page and line numbers are displayed in the margin. Absent other instructions, a page and line number or line number range implies all of the indicated text is to be replaced by immediately following text, while a page and line number followed by + indicates that immediately following text is to be inserted after the indicated line. Remarks for the editor are noted in the margin, or appear between [ and ] in the text.

[Editor: Delete “If ... definition.” See the edit indicated for [55:24+] below.] 49:9-10

[Editor: Delete “and all the components of the type”. See the edit indicated for [55:24+] below.] 55:23

Constraint: There shall be no component-spec that directly corresponds to an inaccessible com- 55:24+

ponent.

Note to J3: The term “directly corresponds” is introduced in paper 00-251. Not an Edit