Skip to content

Commit 283d466

Browse files
committed
Reverts commits from 65826db to 9cea4e7
Revert "local refactorings: looks for the innermost scope" This reverts commit 9cea4e7. Revert "return on error and report back the error message" This reverts commit b8802f3. Revert "simplify the refactoring logic" This reverts commit df13448. Revert "simpler returns" This reverts commit 75e2592. Revert "local refactor only on the current scope" This reverts commit 486b619. Revert "improve toplevel binding detection logic" This reverts commit 517d645. Revert "handle non-writable case" This reverts commit df93c72. Revert "improve parent module detection logic" This reverts commit be7c0d3. Revert "handle entrypath for Main module gracefully" This reverts commit 39392af. Revert "add goto uri 🎉" This reverts commit 6f84942. Revert "organize description" This reverts commit d746383. Revert "global refactor only from its definition" This reverts commit e4d7ee4. Revert "moar docs" This reverts commit bf977e5. Revert "create uri utilities" This reverts commit 713312a. Revert "even better messaging" This reverts commit 4682c11. Revert "jumpable global rename refactor information" This reverts commit e618a16. Revert "add more methods for get utilities" This reverts commit 79bd617. Revert "better messaging & suppress field renaming" This reverts commit abbb84c. Revert "global refactoring" This reverts commit e2da219. Revert "local refactoring" This reverts commit 65826db. Date: Wed Oct 23 19:43:30 2019 +0900 Changes to be committed: modified: src/Atom.jl modified: src/completions.jl deleted: src/docs.jl modified: src/refactor.jl modified: src/utils.jl modified: test/goto.jl
1 parent 9cea4e7 commit 283d466

6 files changed

Lines changed: 22 additions & 327 deletions

File tree

src/Atom.jl

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
__precompile__()
22

3-
@doc read(joinpath(dirname(@__DIR__), "README.md"), String)
43
module Atom
54

65
using Juno, Lazy, JSON, MacroTools, Media, Base.StackTraces
@@ -52,7 +51,6 @@ include("outline.jl")
5251
include("completions.jl")
5352
include("goto.jl")
5453
include("datatip.jl")
55-
include("refactor.jl")
5654
include("misc.jl")
5755
include("formatter.jl")
5856
include("frontend.jl")

src/completions.jl

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -145,14 +145,19 @@ completionurl(c::REPLCompletions.ModuleCompletion) = begin
145145
mod, name = c.parent, c.mod
146146
val = getfield′(mod, name)
147147
if val isa Module # module info
148-
urimoduleinfo(parentmodule(val) == val || val (Base, Core) ? name : "$mod.$name")
148+
parentmodule(val) == val || val (Main, Base, Core) ?
149+
"atom://julia-client/?moduleinfo=true&mod=$(name)" :
150+
"atom://julia-client/?moduleinfo=true&mod=$(mod).$(name)"
149151
else
150-
uridocs(mod, name)
152+
"atom://julia-client/?docs=true&mod=$(mod)&word=$(name)"
151153
end
152154
end
153-
completionurl(c::REPLCompletions.MethodCompletion) = uridocs(c.method.module, c.method.name)
154-
completionurl(c::REPLCompletions.PackageCompletion) = urimoduleinfo(c.package)
155-
completionurl(c::REPLCompletions.KeywordCompletion) = uridocs("Main", c.keyword)
155+
completionurl(c::REPLCompletions.MethodCompletion) =
156+
"atom://julia-client/?docs=true&mod=$(c.method.module)&word=$(c.method.name)"
157+
completionurl(c::REPLCompletions.PackageCompletion) =
158+
"atom://julia-client/?moduleinfo=true&mod=$(c.package)"
159+
completionurl(c::REPLCompletions.KeywordCompletion) =
160+
"atom://julia-client/?docs=true&mod=Main&word=$(c.keyword)"
156161

157162
completionmodule(mod, c) = shortstr(mod)
158163
completionmodule(mod, c::REPLCompletions.ModuleCompletion) = shortstr(c.parent)

src/docs.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ function renderitem(x)
3232

3333
mod = getmodule(x.mod)
3434
name = Symbol(x.name)
35-
r[:typ], r[:icon], r[:nativetype] = if (name !== :ans || mod === Base) && iskeyword(name)
35+
r[:typ], r[:icon], r[:nativetype] = if (name !== :ans || mod === Base) && name keys(Docs.keywords)
3636
"keyword", "k", x.typ
3737
else
3838
val = getfield′(mod, name)

src/refactor.jl

Lines changed: 0 additions & 229 deletions
This file was deleted.

0 commit comments

Comments
 (0)