1
0
mirror of https://github.com/gryf/snipmate.vim.git synced 2025-12-28 09:22:35 +01:00

fixed objc/cpp command-based snippets

This commit is contained in:
Michael Sanders
2009-03-01 19:24:43 -05:00
parent dd8b39a9b5
commit a8109fa38f
14 changed files with 18 additions and 52 deletions

View File

@@ -2,8 +2,7 @@ if !exists('loaded_snips') || exists('s:did_perl_snips')
fini
en
let s:did_perl_snips = 1
let ft = &ft
let &ft ='perl'
let snippet_filetype = 'perl'
" Hash Pointer
exe 'Snipp . =>'
@@ -37,5 +36,3 @@ exe 'Snipp xfore ${1:expression} foreach @${2:array};${3}'
exe "Snipp cl package ${1:ClassName};\n\nuse base qw(${2:ParentClass});\n\nsub new {\n\tmy $class = shift;\n\t$class = ref $class if ref $class;\n\tmy $self = bless {}, $class;\n\t$self;\n}\n\n1;${3}"
" Read File
exe "Snipp slurp my $${1:var};\n{ local $/ = undef; local *FILE; open FILE, \"<${2:file}\"; $$1 = <FILE>; close FILE }${2}"
let &ft = ft