VHDL Issue Number: 0104 Classification: Language Definition Problem Language Version: VHDL-87 Summary: Can unary operators be used as type-conversion functions? Related Issues: None. Relevant LRM Sections: 4.3.3.2, 7.2, 7.3.3 Key Words and Phrases: Predefined operators, type-conversion functions Current Status: Submitted 1076-1993 Disposition: Bugs Fixed, Enhancements Outstanding (No ISAC Issues) Disposition Rationale: Superseded By: N/A ----------------------- Date Submitted: 1991/02/11 Author of Submission: Paul Menchini Author's Affiliation: CAD Language Systems, Inc. Author's Post Address: P.O. Box 13036 Research Triangle Park, NC 27709-3036 Author's Phone Number: (919) 361-1913 Author's Fax Number: Author's Net Address: mench@clsi.com ----------------------- Date Analyzed: TBD Author of Analysis: TBD Revision Number: $Revision: 1.9 $ Date Last Revised: $Date: 1995/05/13 19:34:42 $ Description of Problem ---------------------- Can operators be used as type-conversion functions? If so, then can operation notation be used in the formal or actual part of an association involving type conversion? By way of illustration, consider the following four association elements from some port map. Assume that the modes of the formals and the types of the formals and actuals and operators are appropriate: 1. F => "not" (A) 2. F => not A 3. "not" (F) => A 4. not F => A Associations 1 and 3 are syntactically allowed; moreover, because of recent ISAC decisions regarding the semantic equivalence of operators and functions, these associations should furthermore be semantically allowed. Associations 2 and 4 are semantically identical to associations 1 and 3, respectively. However, they are not syntactically allowed. Proposed Resolution ------------------- Allow the unary operators to be used as type-conversion functions in an association list. Moreover, allow operation syntax to be used to specify these operators, in addition to the currently allowed function-call syntax. To implement: 1. Specifically state in Section 4.3.3.2 that operators may be used as the function in a type conversion function. (Alternatively, the equivalence between functions and operators could be established in either of Sections 7.2 or 7.3.3.) 2. Augment the productions for formal_part and actual_part in Section 4.3.3.2 as follows: formal_part ::= formal_designator | *function*_name ( formal_designator ) | unary_operator formal_designator actual_part ::= actual_designator | *function*_name ( actual_designator ) | unary_operator actual_designator 3. Add the production for unary_operator to Section 7.2: unary_operator ::= + | - | abs | not VASG-ISAC Analysis & Rationale ------------------------------ TBD VASG-ISAC Recommendation for IEEE Std 1076-1987 ----------------------------------------------- TBD VASG-ISAC Recommendation for Future Revisions --------------------------------------------- TBD