Branch: refs/heads/master Author: Colomban Wendling ban@herbesfolles.org Committer: Colomban Wendling ban@herbesfolles.org Date: Mon, 24 Jun 2013 21:09:36 UTC Commit: 3ec664f544d940b470ed09e2351a9e1de4966bfa https://github.com/geany/geany/commit/3ec664f544d940b470ed09e2351a9e1de4966b...
Log Message: ----------- Merge Fortran fixes from Alexander Eberspächer
Closes PR#145 and PR#146 by cherry-picking their commits.
Modified Paths: -------------- tagmanager/ctags/fortran.c tests/ctags/Makefile.am tests/ctags/forall_module.f90 tests/ctags/forall_module.f90.tags
Modified: tagmanager/ctags/fortran.c 9 files changed, 8 insertions(+), 1 deletions(-) =================================================================== @@ -84,6 +84,7 @@ KEYWORD_equivalence, KEYWORD_extends, KEYWORD_external, + KEYWORD_forall, KEYWORD_format, KEYWORD_function, KEYWORD_if, @@ -107,6 +108,7 @@ KEYWORD_pointer, KEYWORD_precision, KEYWORD_private, + KEYWORD_procedure, KEYWORD_program, KEYWORD_public, KEYWORD_pure, @@ -249,6 +251,7 @@ { "equivalence", KEYWORD_equivalence }, { "extends", KEYWORD_extends }, { "external", KEYWORD_external }, + { "forall", KEYWORD_forall }, { "format", KEYWORD_format }, { "function", KEYWORD_function }, { "if", KEYWORD_if }, @@ -272,6 +275,7 @@ { "pointer", KEYWORD_pointer }, { "precision", KEYWORD_precision }, { "private", KEYWORD_private }, + { "procedure", KEYWORD_procedure }, { "program", KEYWORD_program }, { "public", KEYWORD_public }, { "pure", KEYWORD_pure }, @@ -1123,6 +1127,7 @@ static boolean isTypeSpec (tokenInfo *const token) case KEYWORD_logical: case KEYWORD_record: case KEYWORD_type: + case KEYWORD_procedure: result = TRUE; break; default: @@ -1185,6 +1190,7 @@ static void parseTypeSpec (tokenInfo *const token) case KEYWORD_integer: case KEYWORD_logical: case KEYWORD_real: + case KEYWORD_procedure: readToken (token); if (isType (token, TOKEN_PAREN_OPEN)) skipOverParens (token); /* skip kind-selector */ @@ -2045,7 +2051,8 @@ static boolean parseExecutionPart (tokenInfo *const token) if (isSecondaryKeyword (token, KEYWORD_do) || isSecondaryKeyword (token, KEYWORD_if) || isSecondaryKeyword (token, KEYWORD_select) || - isSecondaryKeyword (token, KEYWORD_where)) + isSecondaryKeyword (token, KEYWORD_where) || + isSecondaryKeyword (token, KEYWORD_forall)) { skipToNextStatement (token); result = TRUE;
Modified: tests/ctags/Makefile.am 2 files changed, 2 insertions(+), 0 deletions(-) =================================================================== @@ -120,6 +120,7 @@ test_sources = \ enum.java \ events.cs \ extern_variable.h \ + forall_module.f90 \ format.pl \ func_typedef.h \ general.cs \ @@ -184,6 +185,7 @@ test_sources = \ objectivec_property.mm \ objectivec_protocol.mm \ Package.pm \ + procedure_pointer_module.f90 \ property.cs \ prototype.h \ pure_elem.f95 \
Modified: tests/ctags/forall_module.f90 26 files changed, 26 insertions(+), 0 deletions(-) =================================================================== @@ -0,0 +1,26 @@ +! a module that uses a forall block + +module with_forall + + real :: a + +contains + + subroutine sub_with_forall(x) + real, intent(inout) :: x(:) + + integer :: i + + forall(i=1:size(x)) + x(i) = 0.5**i + end forall + end subroutine sub_with_forall + + + function two() result(res) + real :: res + + res = 2.0 + end function two + +end module with_forall
Modified: tests/ctags/forall_module.f90.tags 5 files changed, 5 insertions(+), 0 deletions(-) =================================================================== @@ -0,0 +1,5 @@ +# format=tagmanager +a�16384�with_forall�0 +sub_with_forall�64�with_forall�0 +two�16�with_forall�0 +with_forall�256�0
-------------- This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).