@@ -370,27 +370,27 @@ logical function matchplus(p, pattern, text, it0, matchlength)
370370 end function matchplus
371371
372372 ! Find matches of the given pattern in the string
373- integer function re_match (text , pattern , length ) result(index)
373+ integer function re_match (string , pattern , length ) result(index)
374374 character (* ,kind= RCK), intent (in ) :: pattern
375- character (* ,kind= RCK), intent (in ) :: text
375+ character (* ,kind= RCK), intent (in ) :: string
376376 integer , intent (out ) :: length
377377 type (regex_op) :: command
378378
379379 command = parse_pattern(pattern)
380- index = re_matchp(text ,command,length)
380+ index = re_matchp(string ,command,length)
381381
382382 end function re_match
383383
384384 ! Find matches of the given pattern in the string
385- integer function re_match_nolength (text , pattern ) result(index)
385+ integer function re_match_nolength (string , pattern ) result(index)
386386 character (* ,kind= RCK), intent (in ) :: pattern
387- character (* ,kind= RCK), intent (in ) :: text
387+ character (* ,kind= RCK), intent (in ) :: string
388388
389389 type (regex_op) :: command
390390 integer :: length
391391
392392 command = parse_pattern(pattern)
393- index = re_matchp(text ,command,length)
393+ index = re_matchp(string ,command,length)
394394
395395 end function re_match_nolength
396396
@@ -575,17 +575,17 @@ logical function pat_match(p, c) result(match)
575575
576576 end function pat_match
577577
578- integer function re_matchp_nolength (text , pattern ) result(index)
578+ integer function re_matchp_nolength (string , pattern ) result(index)
579579 type (regex_op), intent (in ) :: pattern
580- character (len=* ,kind= RCK), intent (in ) :: text
580+ character (len=* ,kind= RCK), intent (in ) :: string
581581 integer :: matchlength
582- index = re_matchp(text , pattern, matchlength)
582+ index = re_matchp(string , pattern, matchlength)
583583 end function re_matchp_nolength
584584
585585
586- integer function re_matchp (text , pattern , matchlength ) result(index)
586+ integer function re_matchp (string , pattern , matchlength ) result(index)
587587 type (regex_op), intent (in ) :: pattern
588- character (len=* ,kind= RCK), intent (in ) :: text
588+ character (len=* ,kind= RCK), intent (in ) :: string
589589 integer , intent (out ) :: matchlength
590590
591591 matchlength = 0
@@ -595,12 +595,12 @@ integer function re_matchp(text, pattern, matchlength) result(index)
595595 if (pattern% pattern(1 )% type == BEGIN_WITH) then
596596
597597 ! String must begin with this pattern
598- index = merge (1 ,0 ,matchpattern(pattern% pattern(2 :), text , matchlength))
598+ index = merge (1 ,0 ,matchpattern(pattern% pattern(2 :), string , matchlength))
599599
600600 else
601601
602- do index= 1 ,len (text )
603- if (matchpattern(pattern% pattern,text (index:),matchlength)) return
602+ do index= 1 ,len (string )
603+ if (matchpattern(pattern% pattern,string (index:),matchlength)) return
604604 end do
605605
606606 index = 0
@@ -617,11 +617,6 @@ integer function re_matchp(text, pattern, matchlength) result(index)
617617 end function re_matchp
618618
619619
620-
621-
622-
623-
624-
625620 ! Iterative matching
626621 logical function matchpattern (pattern , text , matchlength ) result(match)
627622 class(regex_pattern), intent (in ) :: pattern(:)
0 commit comments