From 7950ee5de8f544128e0fc2bd902c312c68ac4456 Mon Sep 17 00:00:00 2001 From: Blaine Bublitz Date: Tue, 13 Jun 2023 11:41:01 +0100 Subject: [PATCH] chore: Upgrade codespan dependencies (#1647) --- Cargo.lock | 8 ++++---- Cargo.toml | 4 ++-- crates/fm/src/file_map.rs | 2 +- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 90260cc3009..851ebce002b 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -692,18 +692,18 @@ checksum = "2da6da31387c7e4ef160ffab6d5e7f00c42626fe39aea70a7b0f1773f7dd6c1b" [[package]] name = "codespan" -version = "0.9.5" +version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ebaf6bb6a863ad6aa3a18729e9710c53d75df03306714d9cc1f7357a00cd789" +checksum = "3362992a0d9f1dd7c3d0e89e0ab2bb540b7a95fea8cd798090e758fda2899b5e" dependencies = [ "codespan-reporting", ] [[package]] name = "codespan-reporting" -version = "0.9.5" +version = "0.11.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e0762455306b1ed42bc651ef6a2197aabda5e1d4a43c34d5eab5c1a3634e81d" +checksum = "3538270d33cc669650c4b093848450d380def10c331d38c768e34cac80576e6e" dependencies = [ "termcolor", "unicode-width", diff --git a/Cargo.toml b/Cargo.toml index 38231e4bb24..98b46245a78 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -40,8 +40,8 @@ noir_wasm = { path = "crates/wasm" } cfg-if = "1.0.0" clap = { version = "4.1.4", features = ["derive"] } -codespan = "0.9.5" -codespan-reporting = "0.9.5" +codespan = "0.11.1" +codespan-reporting = "0.11.1" chumsky = { git = "https://github.com/jfecher/chumsky", rev = "ad9d312" } dirs = "4" serde = { version = "1.0.136", features = ["derive"] } diff --git a/crates/fm/src/file_map.rs b/crates/fm/src/file_map.rs index 150451df9ba..4dbfbece0e0 100644 --- a/crates/fm/src/file_map.rs +++ b/crates/fm/src/file_map.rs @@ -62,7 +62,7 @@ impl FileMap { FileId(file_id) } pub fn get_file(&self, file_id: FileId) -> Option { - self.0.get(file_id.0).map(File) + self.0.get(file_id.0).map(File).ok() } }