Fixed #649: Silly regex bug

This commit is contained in:
Karl Yngve Lervåg 2017-01-04 12:37:36 +01:00
parent 4c76e8f740
commit baa6467bc6
2 changed files with 4 additions and 2 deletions

View File

@ -81,7 +81,7 @@ if get(g:, 'tex_fast', 'r') =~# 'r'
\ '[Ppf]?[Nn]otecite', \ '[Ppf]?[Nn]otecite',
\] \]
execute 'syntax match texStatement' execute 'syntax match texStatement'
\ '/\v\\' . s:pattern . '\ze\s*\{/' \ '/\v\\' . s:pattern . '\ze\s*%(\[|\{)/'
\ 'nextgroup=texRefOption,texCite' \ 'nextgroup=texRefOption,texCite'
endfor endfor
@ -97,7 +97,7 @@ if get(g:, 'tex_fast', 'r') =~# 'r'
\ 'cite%(field|list|name)', \ 'cite%(field|list|name)',
\] \]
execute 'syntax match texStatement' execute 'syntax match texStatement'
\ '/\v\\' . s:pattern . '\ze\s*\{/' \ '/\v\\' . s:pattern . '\ze\s*%(\[|\{)/'
\ 'nextgroup=texRefOptions,texCites' \ 'nextgroup=texRefOptions,texCites'
endfor endfor

View File

@ -90,6 +90,8 @@ const double pi = 3.1415926535
% Cite commands % Cite commands
\cite{} \cite{}
\citet*{} \citet*{}
\citep{bibtexkey1}
\citep[e.g.][]{bibtexkey2}
\citealt{} \citealt{}
\citealt*{} \citealt*{}
\citealp{} \citealp{}