From dea6d9b73b773b2072fcfaa46e6b8989c51d241f Mon Sep 17 00:00:00 2001 From: Vincent Ambo Date: Mon, 12 Sep 2022 00:34:25 +0300 Subject: chore(tvix/eval): add dependency on codemap-diagnostic This is a crate for source-span based error reporting. Since all of our spans are already codemap spans, it is a good starting point. We have to figure out quite a bit of logic for neat error printing; later on if we want fancier presentation we might want to look at one of the other libraries in this space like miette. Change-Id: I4e28886af1ed199b7112d9dbf063c9f29b612bf1 Reviewed-on: https://cl.tvl.fyi/c/depot/+/6531 Autosubmit: tazjin Tested-by: BuildkiteCI Reviewed-by: sterni Reviewed-by: grfn --- corp/tvixbolt/Cargo.lock | 50 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) (limited to 'corp/tvixbolt/Cargo.lock') diff --git a/corp/tvixbolt/Cargo.lock b/corp/tvixbolt/Cargo.lock index 4de42d9d34be..60b20eb43d0e 100644 --- a/corp/tvixbolt/Cargo.lock +++ b/corp/tvixbolt/Cargo.lock @@ -2,6 +2,17 @@ # It is not intended for manual editing. version = 3 +[[package]] +name = "atty" +version = "0.2.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d9b39be18770d11421cdb1b9947a45dd3f37e93092cbf377614828a319d5fee8" +dependencies = [ + "hermit-abi", + "libc", + "winapi", +] + [[package]] name = "autocfg" version = "1.1.0" @@ -38,6 +49,17 @@ version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b9e769b5c8c8283982a987c6e948e540254f1058d5a74b8794914d4ef5fc2a24" +[[package]] +name = "codemap-diagnostic" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4ba0e6be8e2774e750f9e90625b490249715bece38a12f9d09e82477caba5028" +dependencies = [ + "atty", + "codemap", + "termcolor", +] + [[package]] name = "console_error_panic_hook" version = "0.1.7" @@ -200,6 +222,15 @@ version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" +[[package]] +name = "hermit-abi" +version = "0.1.19" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "62b467343b94ba476dcb2500d242dadbb39557df889310ac77c5d99100aaac33" +dependencies = [ + "libc", +] + [[package]] name = "indexmap" version = "1.9.1" @@ -437,6 +468,15 @@ dependencies = [ "unicode-width", ] +[[package]] +name = "termcolor" +version = "1.1.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "bab24d30b911b2376f3a13cc2cd443142f0c81dda04c118693e35b3835757755" +dependencies = [ + "winapi-util", +] + [[package]] name = "text-size" version = "1.1.0" @@ -468,6 +508,7 @@ name = "tvix-eval" version = "0.1.0" dependencies = [ "codemap", + "codemap-diagnostic", "dirs", "path-clean", "rnix", @@ -604,6 +645,15 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ac3b87c63620426dd9b991e5ce0329eff545bccbbb34f3be09ff6fb6ab51b7b6" +[[package]] +name = "winapi-util" +version = "0.1.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "70ec6ce85bb158151cae5e5c87f95a8e97d2c0c4b001223f33a334e3ce5de178" +dependencies = [ + "winapi", +] + [[package]] name = "winapi-x86_64-pc-windows-gnu" version = "0.4.0" -- cgit 1.4.1