File tree Expand file tree Collapse file tree 3 files changed +24
-2
lines changed Expand file tree Collapse file tree 3 files changed +24
-2
lines changed Original file line number Diff line number Diff line change @@ -245,7 +245,7 @@ static const char *const RegexStrURL =
245
245
#define MARKUP_SIMPLE_FIELD (Id, Keyword, XMLKind ) \
246
246
#Keyword " |"
247
247
static const char *const RegexStrDocCommentField =
248
- " ^[ ]? - ("
248
+ " ^[ ]* - ("
249
249
#include " swift/Markup/SimpleFields.def"
250
250
" returns):" ;
251
251
Original file line number Diff line number Diff line change @@ -168,6 +168,18 @@ func foo(n: Float) -> Int {
168
168
return 100009
169
169
}
170
170
171
+ ///- returns: single-line, no space
172
+ // CHECK: ///- <doc-comment-field>returns</doc-comment-field>: single-line, no space
173
+
174
+ /// - returns: single-line, 1 space
175
+ // CHECK: /// - <doc-comment-field>returns</doc-comment-field>: single-line, 1 space
176
+
177
+ /// - returns: single-line, 2 spaces
178
+ // CHECK: /// - <doc-comment-field>returns</doc-comment-field>: single-line, 2 spaces
179
+
180
+ /// - returns: single-line, more spaces
181
+ // CHECK: /// - <doc-comment-field>returns</doc-comment-field>: single-line, more spaces
182
+
171
183
// CHECK: <kw>protocol</kw> Prot {
172
184
protocol Prot {
173
185
// CHECK: <kw>typealias</kw> Blarg
Original file line number Diff line number Diff line change 361
361
{
362
362
key.kind: source.lang.swift.syntaxtype.doccomment,
363
363
key.offset: 666,
364
- key.length: 59
364
+ key.length: 13
365
+ },
366
+ {
367
+ key.kind: source.lang.swift.syntaxtype.doccomment.field,
368
+ key.offset: 679,
369
+ key.length: 8
370
+ },
371
+ {
372
+ key.kind: source.lang.swift.syntaxtype.doccomment,
373
+ key.offset: 687,
374
+ key.length: 38
365
375
},
366
376
{
367
377
key.kind: source.lang.swift.syntaxtype.keyword,
You can’t perform that action at this time.
0 commit comments