You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Change filetype detection into whole word match, the default wildcard way doesn't support overwriting in language like foo and foobar.
For example, I have extended a systemverilog.snippets from verilog.snippets,
in verilog.snippets file:
priority -50
snippet comb "Infer combinational from always" b
always @(*) begin
${1:${VISUAL}}
end
$0
endsnippet
in the systemverilog.snippets file:
priority -50
extends verilog
# We want to overwrite everything in parent ft.
priority -49
snippet comb "Infer combinational from always_comb" b
always_comb begin
${1:${VISUAL}}
end
$0
endsnippet
comb<tab> is expected to be replaced with always @(*) in verilog file and always_comb in systemverilog file.
Actual behavior:
For previous example, comb<tab> in any verilog file will be replaced with always_comb instead of always @(*).
Steps to reproduce
install ultisnips and honza/vim-snippets plugins
disable searching snipmate snippets by adding let g:UltiSnipsEnableSnipMate = 0 to .vimrc
open test.v file and set filetype with :set filetype=verilog
test with previous example, i.e., write comb<tab>
Operating System:
Ubuntu 22.04
Vim Version:
VIM - Vi IMproved 8.2 (2019 Dec 12, compiled Sep 13 2022 09:35:02)
Included patches: 1-3995, 4563, 4646, 4774, 4895, 4899, 4901, 4919
Expected behavior:
Change filetype detection into whole word match, the default wildcard way doesn't support overwriting in language like
foo
andfoobar
.For example, I have extended a
systemverilog.snippets
fromverilog.snippets
,in
verilog.snippets
file:in the
systemverilog.snippets
file:comb<tab>
is expected to be replaced withalways @(*)
in verilog file andalways_comb
in systemverilog file.Actual behavior:
For previous example,
comb<tab>
in any verilog file will be replaced withalways_comb
instead ofalways @(*)
.Steps to reproduce
ultisnips
andhonza/vim-snippets
pluginslet g:UltiSnipsEnableSnipMate = 0
to .vimrctest.v
file and set filetype with:set filetype=verilog
comb<tab>
Ubuntu 22.04
VIM - Vi IMproved 8.2 (2019 Dec 12, compiled Sep 13 2022 09:35:02)
Included patches: 1-3995, 4563, 4646, 4774, 4895, 4899, 4901, 4919
e99fdf1
5.10.6 (main, Nov 2 2022, 18:53:38) [GCC 11.3.0]
The text was updated successfully, but these errors were encountered: