Skip to content

Commit

Permalink
feat: support rust 1.81.0
Browse files Browse the repository at this point in the history
  • Loading branch information
ognevny committed Sep 13, 2024
1 parent 8d625a6 commit 6d18865
Show file tree
Hide file tree
Showing 5 changed files with 4 additions and 9 deletions.
1 change: 0 additions & 1 deletion crates/turborepo-lib/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
#![feature(hash_extract_if)]
#![feature(option_get_or_insert_default)]
#![feature(once_cell_try)]
#![feature(panic_info_message)]
#![feature(try_blocks)]
#![feature(impl_trait_in_assoc_type)]
#![deny(clippy::all)]
Expand Down
7 changes: 2 additions & 5 deletions crates/turborepo-lib/src/panic_handler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,8 @@ use crate::get_version;
const OPEN_ISSUE_MESSAGE: &str =
"Please open an issue at https://github.com/vercel/turborepo/issues/new/choose";

pub fn panic_handler(panic_info: &std::panic::PanicInfo) {
let cause = panic_info
.message()
.map(ToString::to_string)
.unwrap_or_else(|| "Unknown".to_string());
pub fn panic_handler(panic_info: &std::panic::PanicHookInfo) {
let cause = panic_info.to_string();

let explanation = match panic_info.location() {
Some(location) => format!("file '{}' at line {}\n", location.file(), location.line()),
Expand Down
2 changes: 1 addition & 1 deletion crates/turborepo-paths/src/absolute_system_path.rs
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ impl AbsoluteSystemPath {

pub fn try_exists(&self) -> Result<bool, PathError> {
// try_exists is an experimental API and not yet in fs_err
Ok(std::fs::try_exists(&self.0)?)
Ok(std::fs::exists(&self.0)?)
}

pub fn extension(&self) -> Option<&str> {
Expand Down
1 change: 0 additions & 1 deletion crates/turborepo-paths/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#![feature(assert_matches)]
#![feature(fs_try_exists)]
#![deny(clippy::all)]

//! Turborepo's path handling library.
Expand Down
2 changes: 1 addition & 1 deletion rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[toolchain]
channel = "nightly-2024-05-31"
channel = "nightly-2024-07-19"
components = ["rustfmt", "clippy"]
profile = "minimal"

0 comments on commit 6d18865

Please sign in to comment.