Copyright © 2006 IEEE. All rights reserved.
Interpretation Number: 018
Topic: expr invalid_opearand
Relevant Sections: expr STDOUT------------------------------------------------------------------------
7 Defect Report concerning (number and title of International Standard or DIS final text, if applicable):
The Shell and Utilities Volume of IEEE Std 1003.1-2001
------------------------------------------------------------------------
8 Qualifier (e.g. error, omission, clarification required):
1. Error
------------------------------------------------------------------------
9 References in document (e.g. page, clause, figure, and/or table numbers):
Edition of Specification (Year): 2003 XCU P 429 line 16672 2003 Ed
Reference XCU finaltext ERN 2
------------------------------------------------------------------------
10 Nature of defect (complete, concise explanation of the perceived problem):
For expr _invalid_expression_, the standard appears to require that a newline is required to be output, even though there is no result. This is not historical practice.
------------------------------------------------------------------------
11 Solution proposed by the submitter (optional):
In the STDOUT section Change lines 16672 (2003 Ed) to read: "The expr utility shall evaluate the expression and upon success write the result, followed by a <newline>,...."
------------------------------------------------------------------------
Interpretation response ------------------------ The standard clearly states the requirements,and conforming implementations must conform to this. The CONSEQUENCE OF ERRORS section in 1.11 states that utilities may terminate prematurely if they encounter an invalid argument, therefore a conforming implementation of the expr utility need not write the result to STDOUT.
Rationale: ------------- None.
_____________________________________________________________________________
Back to IEEE Standards Interpretations for IEEE Std 1003.1-2001