Allow for empty lists in ns declaration
This commit is contained in:
parent
b1725f68a1
commit
3ffdb062c6
@ -1432,7 +1432,7 @@ function! fireplace#resolve_alias(name) abort
|
|||||||
endif
|
endif
|
||||||
let _ = {}
|
let _ = {}
|
||||||
for refs in filter(copy(s:ns()), 'type(v:val) == type([])')
|
for refs in filter(copy(s:ns()), 'type(v:val) == type([])')
|
||||||
if a:name =~# '^\u' && refs[0] is# ':import'
|
if a:name =~# '^\u' && get(refs, 0) is# ':import'
|
||||||
for _.ref in refs
|
for _.ref in refs
|
||||||
if type(_.ref) == type([]) && index(_.ref, a:name) > 0
|
if type(_.ref) == type([]) && index(_.ref, a:name) > 0
|
||||||
return _.ref[0] . '.' . a:name
|
return _.ref[0] . '.' . a:name
|
||||||
@ -1441,7 +1441,7 @@ function! fireplace#resolve_alias(name) abort
|
|||||||
endif
|
endif
|
||||||
endfor
|
endfor
|
||||||
endif
|
endif
|
||||||
if refs[0] is# ':require'
|
if get(refs, 0) is# ':require'
|
||||||
for _.ref in refs
|
for _.ref in refs
|
||||||
if type(_.ref) == type([])
|
if type(_.ref) == type([])
|
||||||
let i = index(_.ref, ':as')
|
let i = index(_.ref, ':as')
|
||||||
|
Loading…
Reference in New Issue
Block a user