1
- *indent.txt* For Vim version 9.0. Last change: 2022 Oct 10
1
+ *indent.txt* For Vim version 9.0. Last change: 2023 Dec 05
2
2
3
3
4
4
VIM REFERENCE MANUAL by Bram Moolenaar
@@ -715,7 +715,7 @@ FORTRAN *ft-fortran-indent*
715
715
Block if, select case, where, and forall constructs are indented. So are
716
716
type, interface, associate, block, and enum constructs. The indenting of
717
717
subroutines, functions, modules, and program blocks is optional. Comments,
718
- labelled statements and continuation lines are indented if the Fortran is in
718
+ labeled statements, and continuation lines are indented if the Fortran is in
719
719
free source form, whereas they are not indented if the Fortran is in fixed
720
720
source form because of the left margin requirements. Hence manual indent
721
721
corrections will be necessary for labelled statements and continuation lines
@@ -724,17 +724,16 @@ used for the detection of source format see |ft-fortran-syntax|.
724
724
725
725
Do loops ~
726
726
All do loops are left unindented by default. Do loops can be unstructured in
727
- Fortran with (possibly multiple) loops ending on a labelled executable
727
+ Fortran with (possibly multiple) loops ending on a labeled executable
728
728
statement of almost arbitrary type. Correct indentation requires
729
- compiler-quality parsing. Old code with do loops ending on labelled statements
730
- of arbitrary type can be indented with elaborate programs such as Tidy
731
- (http://www.unb.ca/chem/ajit/f_tidy.htm ). Structured do/continue loops are
732
- also left unindented because continue statements are also used for purposes
733
- other than ending a do loop. Programs such as Tidy can convert structured
734
- do/continue loops to the do/enddo form. Do loops of the do/enddo variety can
735
- be indented. If you use only structured loops of the do/enddo form, you should
736
- declare this by setting the fortran_do_enddo variable in your .vimrc as
737
- follows >
729
+ compiler-quality parsing. Old code with do loops ending on labeled statements
730
+ of arbitrary type can be indented with elaborate programs such as Tidy.
731
+ Structured do/continue loops are also left unindented because continue
732
+ statements are used for purposes other than ending a do loop. Programs such
733
+ as Tidy can convert structured do/continue loops to the do/enddo form. Do
734
+ loops of the do/enddo variety can be indented. If you use only structured
735
+ loops of the do/enddo form, you should declare this by setting the
736
+ fortran_do_enddo variable in your .vimrc as follows >
738
737
739
738
let fortran_do_enddo=1
740
739
@@ -748,15 +747,14 @@ to get do loops indented in .f90 files and left alone in Fortran files with
748
747
other extensions such as .for.
749
748
750
749
Program units ~
751
- The indenting of program units (subroutines, functions, modules, and program
752
- blocks) is enabled by default but can be suppressed if a lighter, screen-width
753
- preserving indent style is desired. To suppress the indenting of program
754
- units for all fortran files set the global fortran_indent_less variable in
755
- your .vimrc as follows >
750
+ Indenting of program units (subroutines, functions, modules, and program
751
+ blocks) can be increased by setting the variable fortran_indent_more and can
752
+ be decreased by setting the variable fortran_indent_less. These variables
753
+ can be set for all fortran files in your .vimrc as follows >
756
754
757
755
let fortran_indent_less=1
758
756
759
- A finer level of suppression can be achieved by setting the corresponding
757
+ A finer level of control can be achieved by setting the corresponding
760
758
buffer-local variable as follows >
761
759
762
760
let b:fortran_indent_less=1
0 commit comments