Comments (6)
Should this be closed by #415?
from rust-analyzer.
There are two bits I'd love to investigate with the new implementation: If I now type mod frobnicate;
and apply a fix to create frobnicate.rs
, the file gets created, but
- editor is not focused to it (that is, file with
mod frobnicate;
is still opened, not the new file) - language server does not receive notification that file is created.
The second is a "bug" in the server implementation: it should listen to file system events, but it doesn't at this point.
The first one looks like something does not work on the typescript side of things. I expect that fixing first should also be a work-around for the second.
from rust-analyzer.
My current suspicions is that created/moved are not assigned for some reason: https://github.com/rust-analyzer/rust-analyzer/blob/481713a0e17e1557288e88a6b1a173b111792998/editors/code/src/commands/apply_source_change.ts#L17-L21
from rust-analyzer.
It turns out that there's multiple overloads of vscode.workspace.openTextDocument
and we should use https://code.visualstudio.com/api/references/vscode-api#2280 but if a string
is passed it means something different.
from rust-analyzer.
Now that that's working a textDocument/didOpen
and then a textDocument/publishDiagnostics
notification is recieved for the new file, should there be others?
from rust-analyzer.
It turns out that there's multiple overloads of vscode.workspace.openTextDocument and we should use https://code.visualstudio.com/api/references/vscode-api#2280 but if a string is passed it means something different.
😨
Now that that's working a textDocument/didOpen and then a textDocument/publishDiagnostics notification is recieved for the new file, should there be others?
No, that's all that is expected. It would still be good to fix underlying vfs issue, but that can be tricky. Opened #433 for that.
from rust-analyzer.
Related Issues (20)
- I'm using a proc_macro, rust-analyzer makes cargo recompile every dependencies HOT 1
- Hovering over numeric literals should show their type HOT 3
- Duplicate method completion from custom snippets HOT 3
- "rewriting static" (the words) forcibly inserted at top of file on save
- A Plan for Making Rust Analyzer Faster HOT 5
- `generate_from_impl_for_enum` should be applicable on the enum itself, generating for all variants at once HOT 1
- Invalid RA diagnostic error: expected 2 arguments, found 1
- Stack overflow when calling "impl Fn(&impl Trait)" HOT 2
- “Inline variable” assist doesn't adjust formatting macros HOT 4
- No completions offered after async keyword HOT 2
- Give `simd-json` a try
- An "unused variables `p`" problem always exists HOT 11
- `include!` macro can't include files outside of project's directory. HOT 1
- entered unreachable code: uncaught type error: pattern (_ : {error}, _ : {error}) has inconsistent arity HOT 2
- thread 'Worker' has overflowed its stack HOT 2
- Implicit drops aren't rendered in `async` functions HOT 1
- Type inference breaks for types with generic lifetimes and generic type parameters with default values HOT 2
- More IDE features for control flow keywords HOT 7
- RA not resolving type that depends on the value of a const expr.
- Possible lifetime recursion causes unresponsive behaviour HOT 1
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 rust-analyzer.