blob: 7d22f46bbdec09d0b003e5d50e7fbfe063969a22 [file] [log] [blame]
dkearns04e53632024-04-11 06:18:37 +10001vim9script
2
3# Vim comments
4
5# Vim9-script comment
6
7 # string only recognised with leading char
8 "useless string"
9
10function! Foo()
11 " Legacy-script comment
12 # 42 " comment
13endfunction
14
15def! Bar()
16 # Vim9-script comment
17 "useless string" # comment
18enddef
19
20command -count FooCommand {
21 # Vim9-script comment
22 "useless string" # comment
23}
24
25autocmd BufNewFile * {
26 # Vim9-script comment
27 "useless string" # comment
28}
29
30
dkearns059cbe82024-06-12 03:27:53 +100031# Multiline comments
32
33# comment
34 \ continuing comment
35 \ continuing comment
36
Doug Kearnsc29b5332025-04-26 20:14:15 +020037var foo = 42 # commment
38 \ continuing comment
39 \ continuing comment
40
dkearns059cbe82024-06-12 03:27:53 +100041# :Foo
42 \ arg1
43 #\ comment
44 \ arg2
45
46echo "TOP"
47
48
49# Line-continuation comments
50
51:Foo
52 #\ line continuation comment
53 \ arg1
54 #\ line continuation comment
55 \ arg2
56
57
dkearns04e53632024-04-11 06:18:37 +100058# Issue: #13047
59
60if !exists(":DiffOrig")
61 command DiffOrig vert new | set bt=nofile | r ++edit %% | 0d_ | diffthis
62 \ | wincmd p | diffthis
63endif
64
65
66# Issue: #11307 and #11560
67
68# This is what we call " blah