Mercurial > vim
view runtime/indent/readline.vim @ 19017:d9ea4f0bfd34 v8.2.0069
patch 8.2.0069: ETYPE_ is used for two different enums
Commit: https://github.com/vim/vim/commit/87396072c5c468f0c129e4ec7cd944ac897b7752
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Dec 31 22:36:18 2019 +0100
patch 8.2.0069: ETYPE_ is used for two different enums
Problem: ETYPE_ is used for two different enums.
Solution: Rename one to use EXPR_.
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Tue, 31 Dec 2019 22:45:03 +0100 |
parents | d0a20101ecb2 |
children | 9c221ad9634a |
line wrap: on
line source
" Vim indent file " Language: readline configuration file " Previous Maintainer: Nikolai Weibull <now@bitwi.se> " Latest Revision: 2006-12-20 if exists("b:did_indent") finish endif let b:did_indent = 1 setlocal indentexpr=GetReadlineIndent() setlocal indentkeys=!^F,o,O,=$else,=$endif setlocal nosmartindent if exists("*GetReadlineIndent") finish endif function GetReadlineIndent() let lnum = prevnonblank(v:lnum - 1) if lnum == 0 return 0 endif let ind = indent(lnum) if getline(lnum) =~ '^\s*$\(if\|else\)\>' let ind = ind + shiftwidth() endif if getline(v:lnum) =~ '^\s*$\(else\|endif\)\>' let ind = ind - shiftwidth() endif return ind endfunction