All patches and comments are welcome. Please squash your changes to logical
commits before using git-format-patch and git-send-email to
patches@git.madduck.net.
If you'd read over the Git project's submission guidelines and adhered to them,
I'd be especially grateful.
summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
d9efc96)
Fixes https://github.com/Vimjas/vim-python-pep8-indent/issues/114
" jedi* refers to syntax definitions from jedi-vim for call signatures, which
" are inserted temporarily into the buffer.
let s:skip_special_chars = 'synIDattr(synID(line("."), col("."), 0), "name") ' .
" jedi* refers to syntax definitions from jedi-vim for call signatures, which
" are inserted temporarily into the buffer.
let s:skip_special_chars = 'synIDattr(synID(line("."), col("."), 0), "name") ' .
- \ '=~? "\\vstring|comment|pythonbytes|jedi\\S"'
+ \ '=~? "\\vstring|comment|^pythonbytes%(contents)=$|jedi\\S"'
let s:skip_after_opening_paren = 'synIDattr(synID(line("."), col("."), 0), "name") ' .
\ '=~? "\\vcomment|jedi\\S"'
let s:skip_after_opening_paren = 'synIDattr(synID(line("."), col("."), 0), "name") ' .
\ '=~? "\\vcomment|jedi\\S"'
describe "handles byte strings" do
before(:all) {
vim.command 'syn region pythonBytes start=+[bB]"+ skip=+\\\\\|\\"\|\\$+ excludenl end=+"+ end=+$+ keepend contains=pythonBytesError,pythonBytesContent,@Spell'
describe "handles byte strings" do
before(:all) {
vim.command 'syn region pythonBytes start=+[bB]"+ skip=+\\\\\|\\"\|\\$+ excludenl end=+"+ end=+$+ keepend contains=pythonBytesError,pythonBytesContent,@Spell'
+ vim.command "syn match pythonBytesEscape '\\\\$'"
vim.feedkeys 'o'
indent.should == 0
end
vim.feedkeys 'o'
indent.should == 0
end
+
+ it "it indents backslash continuation correctly" do
+ vim.feedkeys 'iwith foo, \<Bslash>\<Esc>'
+ vim.echo('getline(".")').should == "with foo, \\"
+ vim.echo('map(synstack(line("."), col(".")), "synIDattr(v:val, \"name\")")'
+ ).should == "['pythonBytesEscape']"
+ vim.feedkeys 'o'
+ indent.should == 8
+ end