When opening several files of the same filetype and AutoPairsDefine is used
with au FileType … let b:AutoPairs = …, AutoPairsDefine is called several
times but reuses the same dictionary set in the first call to AutoPairsDefine.
Let's assume we use
au FileType verilog let b:AutoPairs = AutoPairsDefine({}, ['`'])
On the first buffer it removes the pair
"`": "`"
but the key no longer exists in g:autopairs_defaultpairs when the other buffers are loaded
resulting in ugly error messages.
When opening several files of the same filetype and AutoPairsDefine is used with
au FileType … let b:AutoPairs = …
, AutoPairsDefine is called several times but reuses the same dictionary set in the first call to AutoPairsDefine.Let's assume we use
On the first buffer it removes the pair
but the key no longer exists in
g:autopairs_defaultpairs
when the other buffers are loaded resulting in ugly error messages.This PR fixes that issue.