mirror of
https://github.com/neovim/neovim.git
synced 2025-12-07 23:22:39 +00:00
vim-patch:8.0.0148 #7344
Problem: When a C preprocessor statement has two line continuations the
following line does not have the right indent. (Ken Takata)
Solution: Add the indent of the previous continuation line. (Hirohito
Higashi)
c6aa475a27
This commit is contained in:
@@ -4718,4 +4718,38 @@ describe('cindent', function()
|
||||
JSEND
|
||||
]=])
|
||||
end)
|
||||
|
||||
it('line continuations in macros / vim-patch 8.0.0148', function()
|
||||
insert_([=[
|
||||
/* start of define */
|
||||
{
|
||||
}
|
||||
#define AAA \
|
||||
BBB\
|
||||
CCC
|
||||
|
||||
#define CNT \
|
||||
1 + \
|
||||
2 + \
|
||||
4
|
||||
/* end of define */]=])
|
||||
|
||||
feed_command('set cino&')
|
||||
feed_command('/start of define')
|
||||
feed('=/end of define<cr>')
|
||||
|
||||
expect([=[
|
||||
/* start of define */
|
||||
{
|
||||
}
|
||||
#define AAA \
|
||||
BBB\
|
||||
CCC
|
||||
|
||||
#define CNT \
|
||||
1 + \
|
||||
2 + \
|
||||
4
|
||||
/* end of define */]=])
|
||||
end)
|
||||
end)
|
||||
|
||||
Reference in New Issue
Block a user