on master help sign in
Need to allow this lint, the Hook signature requires Option<>.
commit0e5308bce1a6e7d7d00854ae50902546cea9578d authorBlaž Hrastnik <blaz@mxxn.io> dateWed 5 May 2021, 16:25 (5 years ago) parent3cf9a4c
1 file changed+15−1
helix-term/src/commands.rs+15−1
helix-term/src/commands.rs+15−1
@@ -1327,10 +1327,24 @@ pub mod insert {
13271327 }
13281328 }
13291329
1330− // 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) }
1330+ // SignatureHelp {
1331+ // signatures: [
1332+ // SignatureInformation {
1333+ // label: "fn open(&mut self, path: PathBuf, action: Action) -> Result<DocumentId, Error>",
1334+ // documentation: None,
1335+ // parameters: Some(
1336+ // [ParameterInformation { label: Simple("path: PathBuf"), documentation: None },
1337+ // ParameterInformation { label: Simple("action: Action"), documentation: None }]
1338+ // ),
1339+ // active_parameter: Some(0)
1340+ // }
1341+ // ],
1342+ // active_signature: None, active_parameter: Some(0)
1343+ // }
13311344 }
13321345
13331346 // The default insert hook: simply insert the character
1347+ #[allow(clippy::unnecessary_wraps)] // need to use Option<> because of the Hook signature
13341348 fn insert(doc: &Rope, selection: &Selection, ch: char) -> Option<Transaction> {
13351349 let t = Tendril::from_char(ch);
13361350 let transaction = Transaction::insert(doc, selection, t);