aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBlaž Hrastnik2021-05-05 07:25:17 +0000
committerBlaž Hrastnik2021-05-05 07:25:17 +0000
commit0e5308bce1a6e7d7d00854ae50902546cea9578d (patch)
treeaeb762207098f3737896be99fb5a57e855158b3d
parent3cf9a4ceb82978be0671ada244baf2366aa65e6d (diff)
Need to allow this lint, the Hook signature requires Option<>.
-rw-r--r--helix-term/src/commands.rs16
1 files changed, 15 insertions, 1 deletions
diff --git a/helix-term/src/commands.rs b/helix-term/src/commands.rs
index bd65688d..72ebf7f9 100644
--- a/helix-term/src/commands.rs
+++ b/helix-term/src/commands.rs
@@ -1327,10 +1327,24 @@ pub mod insert {
}
}
- // 2021-05-03T17:54:36.326 hx::commands [INFO] SignatureHelp { signatures: [SignatureInformation { label: "fn open(&mut self, path: PathBuf, action: Action) -> Result<DocumentId, Error>", documentation: None, parameters: Some([ParameterInformation { label: Simple("path: PathBuf"), documentation: None }, ParameterInformation { label: Simple("action: Action"), documentation: None }]), active_parameter: Some(0) }], active_signature: None, active_parameter: Some(0) }
+ // SignatureHelp {
+ // signatures: [
+ // SignatureInformation {
+ // label: "fn open(&mut self, path: PathBuf, action: Action) -> Result<DocumentId, Error>",
+ // documentation: None,
+ // parameters: Some(
+ // [ParameterInformation { label: Simple("path: PathBuf"), documentation: None },
+ // ParameterInformation { label: Simple("action: Action"), documentation: None }]
+ // ),
+ // active_parameter: Some(0)
+ // }
+ // ],
+ // active_signature: None, active_parameter: Some(0)
+ // }
}
// The default insert hook: simply insert the character
+ #[allow(clippy::unnecessary_wraps)] // need to use Option<> because of the Hook signature
fn insert(doc: &Rope, selection: &Selection, ch: char) -> Option<Transaction> {
let t = Tendril::from_char(ch);
let transaction = Transaction::insert(doc, selection, t);