------- Comment #4 from tow21 at cam dot ac dot uk 2007-10-31 13:58 ------- (Sorry for mis-typed example, I can't cut & paste from the VM I'm working in into my web-browser. Your corrected version is what I meant to type)
Well I'm going from the F95 standard (which is the only one I have to hand; and in any case I am trying to write F95-compliant code here, so I'm not overly concerned about F2003 personally). F95 has no concept of a "specification inquiry" (that I can see). Section (7) of the definition of a "restricted expression" seems to cover mostly the same ground, and reads in full: (7) A reference to an intrinsic function that is (a) an array inquiry function (13.11.15) other than ALLOCATED, (b) the bit inquiry function BIT_SIZE (c) the character enquiry function LEN (d) the kind inquire function KIND, or (e) a numeric inquiry function (13.11.8) and where each argument of the function is (a) a restricted expression (b) a variable whose properties inquired about are not (i) dependent on the upper bound of the last dimension of an assumed-size array, (ii) defined by an expression that is not a restricted expression, or (iii) definable by an ALLOCATE or pointer assignment expression That is - the expression is not allowed under (7) - but it is under (8). -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33957