comparison runtime/doc/indent.txt @ 20621:d30b16692ce0 v8.2.0864

patch 8.2.0864: pragmas are indented all the way to the left Commit: https://github.com/vim/vim/commit/d881b516da0184052d2f9d33c3f72c5c014316bd Author: Bram Moolenaar <Bram@vim.org> Date: Sun May 31 17:49:30 2020 +0200 patch 8.2.0864: pragmas are indented all the way to the left Problem: Pragmas are indented all the way to the left. Solution: Add an option to indent progmas like normal code. (Max Rumpf, closes #5468)
author Bram Moolenaar <Bram@vim.org>
date Sun, 31 May 2020 18:00:03 +0200
parents af69c9335223
children 1b345fb68ae3
comparison
equal deleted inserted replaced
20620:3c6739c316cc 20621:d30b16692ce0
568 When N is zero (default): don't recognize '#' comments, do 568 When N is zero (default): don't recognize '#' comments, do
569 recognize preprocessor lines; right-shifting lines that start 569 recognize preprocessor lines; right-shifting lines that start
570 with "#" does not work. 570 with "#" does not work.
571 571
572 572
573 PN When N is non-zero recognize C pragmas, and indent them like any
574 other code; does not concern other preprocessor directives.
575 When N is zero (default): don't recognize C pragmas, treating
576 them like every other preprocessor directive.
577
578
573 The defaults, spelled out in full, are: 579 The defaults, spelled out in full, are:
574 cinoptions=>s,e0,n0,f0,{0,}0,^0,L-1,:s,=s,l0,b0,gs,hs,N0,E0,ps,ts,is,+s, 580 cinoptions=>s,e0,n0,f0,{0,}0,^0,L-1,:s,=s,l0,b0,gs,hs,N0,E0,ps,ts,is,+s,
575 c3,C0,/0,(2s,us,U0,w0,W0,k0,m0,j0,J0,)20,*70,#0 581 c3,C0,/0,(2s,us,U0,w0,W0,k0,m0,j0,J0,)20,*70,#0,P0
576 582
577 Vim puts a line in column 1 if: 583 Vim puts a line in column 1 if:
578 - It starts with '#' (preprocessor directives), if 'cinkeys' contains '#0'. 584 - It starts with '#' (preprocessor directives), if 'cinkeys' contains '#0'.
579 - It starts with a label (a keyword followed by ':', other than "case" and 585 - It starts with a label (a keyword followed by ':', other than "case" and
580 "default") and 'cinoptions' does not contain an 'L' entry with a positive 586 "default") and 'cinoptions' does not contain an 'L' entry with a positive