doc comment changes
This commit is contained in:
parent
0e47eee5a4
commit
a973de5f87
@ -77,7 +77,7 @@ Your editor can send these settings using one of these two methods:
|
||||
fennel-ls is licensed under the MIT license. See LICENSE for more info.
|
||||
This project also contains files from other projects:
|
||||
* test/pl/* comes from [Penlight](https://github.com/lunarmodules/Penlight) [MIT license]
|
||||
* src/json/* comes from [json.lua](https://github.com/rxi/json.lua) [MIT license]
|
||||
* src/json/* is modified, but is originally from [json.lua](https://github.com/rxi/json.lua) [MIT license]
|
||||
* src/fennel-ls/docs/* contains information from the [lua](https://lua.org) reference [MIT license]
|
||||
* test/lust.lua is modified, but originially comes from from [lust](https://github.com/bjornbytes/lust) [MIT license]
|
||||
* fennel and src/fennel.lua are compiled from [fennel](https://git.sr.ht/~technomancy/fennel) [MIT license]
|
||||
|
||||
@ -54,7 +54,8 @@ are declared / referenced in which places."
|
||||
|
||||
(λ line+byte->range [self file line byte]
|
||||
(let [line (- line 1)
|
||||
;; TODO think about this further when upstream bug fennel#180 is fixed
|
||||
;; some errors in fennel erroneously say column -1
|
||||
;; try compiling "(do\n" to see what I mean
|
||||
byte (math.max 0 byte)
|
||||
position (utils.pos->position file.text line byte self.position-encoding)]
|
||||
{:start position :end position}))
|
||||
|
||||
@ -243,15 +243,15 @@ Returns:
|
||||
(table.insert parents ast)
|
||||
(if
|
||||
(or (sequence? ast) (list? ast))
|
||||
(accumulate [(result done) nil
|
||||
(accumulate [(result _parent) nil
|
||||
_ child (ipairs ast)
|
||||
&until result]
|
||||
(if (contains? child byte)
|
||||
(recurse child byte)))
|
||||
(and (not (sym? ast)) (not (varg? ast)))
|
||||
(accumulate [(result done) nil
|
||||
(accumulate [(result _parent) nil
|
||||
key value (pairs ast)
|
||||
&until done]
|
||||
&until result]
|
||||
(if (contains? key byte)
|
||||
(recurse key byte)
|
||||
(contains? value byte)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user