Skip to content

Commit 1d9fa34

Browse files
committed
fixed a bug in add_error
during parsing ('sin'), it was causing a crash when creating the error message
1 parent 50c0639 commit 1d9fa34

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/function_parser.f90

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1471,7 +1471,7 @@ subroutine add_error (me, j, ipos, funcstr, msg)
14711471

14721472
call me%error_msg%add(' '//trim(funcstr))
14731473

1474-
tmp = repeat(' ',ipos(j))//'?' ! Advance to the jth position
1474+
tmp = repeat(' ',ipos(min(j,size(ipos))))//'?' ! Advance to the jth position
14751475
call me%error_msg%add(tmp)
14761476
deallocate(tmp)
14771477

0 commit comments

Comments
 (0)