]> git.lizzy.rs Git - rust.git/commit
Fix Vim indent regressions from #13600.
authorChris Morgan <me@chrismorgan.info>
Thu, 24 Apr 2014 13:33:28 +0000 (23:33 +1000)
committerChris Morgan <me@chrismorgan.info>
Thu, 24 Apr 2014 13:33:28 +0000 (23:33 +1000)
commit7266587f3e52513328926d9229be7003323ceac8
treee564235f3359335c23d0500a23ea0cc3eadff2f7
parente01e78fd00c78fd3b7f92fb0d6d58e05801d5d38
Fix Vim indent regressions from #13600.

The change in #13600 was incorrect, containing a bad regular expression;
inside an indent function, errors are silently ignored (and the ``~=``
operation will return 0), so it just always failed, causing the cases
that were supposed to be caught to not be caught and making things like
the ``match`` example shown above or struct field definitions regress.

I have fixed the regular expression to what it should have been. This is
still imperfect, of course, not handling cases like where the first
argument to a function is a function call (``foo(bar(),``), but it'll do
for now.
src/etc/vim/indent/rust.vim