J3/03-119 To: J3 From: UK Fortran panel Subject: Edits for UK comment TC8 (Remove TYPEALIAS) Date: 11 February 2003 Comment TC8 of the UK vote was: TC8 Remove the TYPEALIAS facility This complicates the language and adds little benefit. We also submitted TC9: Remove the ENUM facility. Since the ENUM definition makes use of TYPEALIAS, two sets of edits are provided. The first is to remove TYPEALIAS. The second is to provide alternative definitions for ENUM in the event that TYPEALIAS is removed and ENUM is retained. Edits to remove TYPEALIAS follow. 10:15. Delete line 14:0+ Table 2.1. Delete "type alias definitions," 14:0+ Table 2.2 Notes: Delete "type alias statements, " 54:0+ Note 4.44 line 2. Delete "to type-alias names or" 54:5+ Note 4.45 line 1. Delete "a type-alias name or" 57:5. Delete line 57:8-9. Delete constraint C463 61:1-13. Delete section 4.6 and Note 4.59 67:23-24. Delete lines, including constraint C503 247:16. Delete "type aliases, " If ENUM is retained: 381:10 Replace "enumerations (4.7), and type aliases (4.6)" by "and enumerations (4.7)" If ENUM is removed: 381:10 Delete ", enumerations (4.7), and type aliases (4.6)" 386:2. Delete " or shall be a type alias name" 396:6. Delete "type aliases, " 401:24. Delete bullet point (15) 419:6. Delete "type alias, " 471:6. Delete line 471:12. Delete "SENDTYPE, " 471:18. Delete line 471:31-34. Delete paragraph 471:35. Replace "fourth" by "third" 472:3. Delete line 472:8. Delete "SENDTYPE, " 472:20-22. Delete paragraph 472:23. Replace "fourth" by "third" Edits to provide an alternative definition for ENUM in the absence of TYPEALIAS follow. 10:9 and elsewhere (i.e. 61:18, 62:15 (twice), 62:27, 62:29, 63:1). Change every occurrence of 'enum-alias-def' to 'enum-def'. 61:15. Change first sentence to An enumeration is a set of named integer constants. 61:22 Delete ':: type-alias-name'. 62:1 Delete '[::] type-alias-name'. 62:4 Delete '[type-alias-name]'. 62:7-8 Delete constraint. 62:9-10. Replace by The kind type parameter for an enumeration is determined as follows: 62:21. Delete 'with type type-alias-name and'. 63:1+. Change NOTE 4.63 to The declarations ENUM (SELECTED_INT_KIND (1)) ENUMERATOR :: ZERO, ONE, TWO END ENUM ENUM, BIND(C) ENUMERATOR :: RED = 4, BLUE = 9 ENUMERATOR YELLOW END ENUM are equivalent to the declarations INTEGER (SELECTED_INT_KIND (1)), PARAMETER :: ZERO = 0, ONE = 1, TWO = 2 ! The kind type parameter for RED, BLUE, and YELLOW is processor dependent, ! but the processor is required to select a kind sufficient to represent the ! values 4, 9, and 10, which are the values of its enumerators. ! The following declaration is one possibility. INTEGER (SELECTED_INT_KIND (2)), PARAMETER :: RED = 4, BLUE = 9, YELLOW = 10