Comments (17)
@Gopiandcode , not a lot of progress on this, as indeed current Search.search
does a linear traverse of the objects in Coq's scope, so I was hoping we could have improved the base Coq's search implementation first.
You are very welcome tho to submit a PR even with the linear scan performance issue, as @JasonGross points out, having a bit of a filter setup would alleviate that. Note that Query
already has a place in the protocol for paginating results and filters.
from coq-lsp.
Any update on whether this will be supported? Are there some fundamental architectural issues that are blocking this feature? If not, I don't mind taking a crack at implementing this in a separate PR - it would be particularly useful for my own projects.
from coq-lsp.
I guess in the meanwhile I am able to make do with:
let evd = Evd.from_env env in
let acc = ref [] in
Search.search env evd query ([], false) (fun refr kind _ typ ->
acc := (refr,kind,typ) :: !acc
)
from coq-lsp.
A question is what kind of object we'd like to return from
Search
, right now we just return names, but certainly a richer information would be appreciated.
The amount of information returned should be configurable, otherwise I expect you'll run into performance issues as company-coq does when trying to find all names available for autocompletion.
from coq-lsp.
Any hope to make a quick and dirty search/searchabout available? Even when writting Search foo
in the document I don't see any result. It's kind of crucial to work on large libraries. And definitely the existing coq-lsp speedup is far more important than Search's performance.
from coq-lsp.
@mattam82 That's strange. Search should show something in the panel. Is your typing cursor over the Search statement?
from coq-lsp.
Ah I see, it was just after the statement
from coq-lsp.
@mattam82 There is an option that shows the messages of the sentence before the cursor which might be useful if you find yourself backtracking alot.
from coq-lsp.
@mattam82 I fully agree we need better search; I've discussed with some people about plans, but so far no one took on it yet, and my backlog is a bit large these days.
Indeed we can now do a bit better with how the cursor works I think, as always this kind of stuff is subtle.
What happens in Coq now when Search foo.
is typed is that the sentence will indeed stop at the point.
I think the option @Alizter mentions doesn't affect the display of messages, but only of goals.
from coq-lsp.
In 0.1.8 for Coq v8.18, I no longer see any results in messages when I use Search/Check/Print. This was not an issue previously on Coq 8.16 with lsp.
from coq-lsp.
@adrianleh Do you see the results when your cursor is over the Search statement or before and after it. There is a configuration option that displays the goal / messages at the cursor vs just before.
from coq-lsp.
I only see it upon mouse-over, however there is no text cursor state (either before or after the period) where is see it.
from coq-lsp.
Screen.Recording.2024-01-30.at.16.04.13.mov
from coq-lsp.
@adrianleh Hmm that is very strange. Does the same happen when you do a check at the top of the file? Sometimes a hanging proof may stop the goal window from being updated.
I have the same version numbers as you and I haven't seen any such issue when using Search.
from coq-lsp.
This happens anywhere in the file
from coq-lsp.
Hi @adrianleh , it seems to me that this is a problem with the extension being activated multiple times, and maybe some configuration mixup.
I think coq-lsp
Zulip could be a better place to discuss this, would you mind if we move the discussion there?
from coq-lsp.
Adding https://coq.zulipchat.com/#narrow/stream/329642-coq-lsp/topic/LSP.20search.20issue/near/419497086 as a reference
from coq-lsp.
Related Issues (20)
- Better copying support HOT 1
- [ci] Windows CI is broken due to outdated Dune version. HOT 1
- _CoqProject won't be loaded from subdirectory HOT 1
- LSP plugin mangling VSCode/ium Settings file HOT 2
- Improvement for goal display HOT 2
- [bug] Properly handle proof mode
- [bug] The selectionRange request only returns the range of one position of the sent positions HOT 6
- Restarting server resets position of goal window HOT 2
- Heatmap for timing and other data
- Prelude Not Loading On #509 HOT 7
- Accumulated performance stats on selection hover HOT 6
- Bug minimizer HOT 12
- [examples] License of examples/chicken.jpg may not be free HOT 3
- [Bug?] Incorrect activation events HOT 4
- coq-lsp connection errors showing in non-Coq projects HOT 5
- Universe information HOT 3
- Slow goal printing in Coq-HoTT theories/Spaces/No/Core.v HOT 2
- Serlib warning HOT 4
- Heatmap disappears when refocusing tab
- "printer interrupted" in goal window HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from coq-lsp.