This is the mail archive of the fortran@gcc.gnu.org mailing list for the GNU Fortran project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: fixed bug in intrinsic "index"


On Wednesday 10 December 2003 10:40, HUANG Chun wrote:
> >Ok. Could you also add a testcase for this.
> >
> >Paul
>
> I find the bug of intrinsic "index" is not modified in the new version.

It is now. Thanks.


> The testcase is following:
>
> ! Program to test the INDEX intrinsic
> program test
>   character(len=10) a
>   integer w
>   if (index("FORTRAN", "R") .ne. 3) call abort
>   if (index("FORTRAN", "R", .TRUE.) .ne. 5) call abort
>   if (w ("FORTRAN") .ne. 3) call abort
> end
>
> function w(str)
>   character(len=8) str
>   integer w
>   w = index(str, "R")
> end

Commited that, too.

Gr.
Steven


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]