mirror of
https://github.com/denoland/deno.git
synced 2025-09-28 21:24:48 +00:00
feat(lsp): add TS quick fix code actions (#9396)
This commit is contained in:
parent
644a7ff2d7
commit
b77fcbc518
13 changed files with 944 additions and 8 deletions
|
@ -37,6 +37,7 @@ use std::cell::RefCell;
|
|||
use std::convert::From;
|
||||
use std::fs::File;
|
||||
use std::io::Read;
|
||||
use std::path::Path;
|
||||
use std::path::PathBuf;
|
||||
use std::pin::Pin;
|
||||
use std::rc::Rc;
|
||||
|
@ -82,7 +83,7 @@ pub fn init(isolate: &mut JsRuntime) {
|
|||
|
||||
pub trait FetchPermissions {
|
||||
fn check_net_url(&self, _url: &Url) -> Result<(), AnyError>;
|
||||
fn check_read(&self, _p: &PathBuf) -> Result<(), AnyError>;
|
||||
fn check_read(&self, _p: &Path) -> Result<(), AnyError>;
|
||||
}
|
||||
|
||||
/// For use with `op_fetch` when the user does not want permissions.
|
||||
|
@ -93,7 +94,7 @@ impl FetchPermissions for NoFetchPermissions {
|
|||
Ok(())
|
||||
}
|
||||
|
||||
fn check_read(&self, _p: &PathBuf) -> Result<(), AnyError> {
|
||||
fn check_read(&self, _p: &Path) -> Result<(), AnyError> {
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue