File tree Expand file tree Collapse file tree 2 files changed +10
-1
lines changed
autoload/vital/__vital__/Text Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -230,9 +230,10 @@ endfunction
230
230
"
231
231
" Offset Date-Time
232
232
" Local Date-Time
233
+ " Local Date
233
234
"
234
235
function ! s: _datetime (input ) abort
235
- return s: _consume (a: input , ' \d\{4}-\d\{2}-\d\{2}[T ]\d\{2}:\d\{2}:\d\{2}\%(\.\d\+\)\?\%(Z\|[+-]\d\{2}:\d\{2}\)\?' )
236
+ return s: _consume (a: input , ' \d\{4}-\d\{2}-\d\{2}\%( [T ]\d\{2}:\d\{2}:\d\{2}\%(\.\d\+\)\?\%(Z\|[+-]\d\{2}:\d\{2}\)\? \)\?' )
236
237
endfunction
237
238
238
239
"
Original file line number Diff line number Diff line change @@ -425,6 +425,14 @@ function! s:suite.__parse__()
425
425
call s: assert .same (data.ldt2, ' 1979-05-27T00:32:00.999999' )
426
426
endfunction
427
427
428
+ function ! parse.local_date ()
429
+ let data = s: TOML .parse (join ([
430
+ \ ' ld1 = 1979-05-27' ,
431
+ \] , " \n " ))
432
+
433
+ call s: assert .same (data.ld1, ' 1979-05-27' )
434
+ endfunction
435
+
428
436
function ! parse.array ()
429
437
let data = s: TOML .parse (join ([
430
438
\ ' integers = [ 1, 2, 3 ]' ,
You can’t perform that action at this time.
0 commit comments