Re: Optional arguments (again) on Sun



On Feb 19, 4:03 pm, nos...@xxxxxxxxxxxxx (Richard Maine) wrote:
Salvatore <sfilipp...@xxxxxxxxxxx> wrote:
Ah. yes, I was missing the small print on the SIZE description,

[that dim must not be an optional dummy argument]

The reason for that small print is that having dim changes the rank of
the result. F90/95/2003 is designed so that the rank of everything is
known at compile time. The presence of an optional dummy argument is not
in general known until run time (and may vary from call to call).

--
Richard Maine | Good judgement comes from experience;
email: last name at domain . net | experience comes from bad judgement.
domain: summertriangle | -- Mark Twain

However, according to my copy of M&R,

"size(array,[dim=]) returns a scalar default integer that is the size
of the array array or extent along dimension dim .... "

so it would seem that your explanation, while certainly appropriate
for LBOUND/UBOUND, is at least surprising here where there seems to
be no such change of rank.

Salvatore

.



Relevant Pages

  • Re: Optional arguments (again) on Sun
    ... The reason for that small print is that having dim changes the rank of ... F90/95/2003 is designed so that the rank of everything is ... known at compile time. ... The presence of an optional dummy argument is not ...
    (comp.lang.fortran)
  • Re: Optional arguments (again) on Sun
    ... The reason for that small print is that having dim changes the rank of ... F90/95/2003 is designed so that the rank of everything is ... known at compile time. ... The presence of an optional dummy argument is not ...
    (comp.lang.fortran)
  • Re: Optional arguments (again) on Sun
    ... [that dim must not be an optional dummy argument] ... The reason for that small print is that having dim changes the rank of ... be no such change of rank. ... bcause that's usually the reason for that kind of restriction. ...
    (comp.lang.fortran)
  • Re: Ranking, subqueries and update query problem
    ... >> Private Sub RankRecord() ... >> Dim rst As Object ... >> ‘Original rank ...
    (microsoft.public.access.queries)
  • Re: Rank function
    ... Dim myUScores() As Double ... Dim iPos As Integer ... iFirst = Application.Match(rSection.Value, rSections, False) ... Section ID No Marks Rank-formula Actual Rank ...
    (microsoft.public.excel.worksheet.functions)