Skip to content

Commit 5bb1c5c

Browse files
diliopfacebook-github-bot
authored andcommitted
Update platform010 & platform010-aarch64 symlinks
Summary: Upgrading Rust from `1.80.1` to `1.81.0` ([release notes](https://blog.rust-lang.org/2024/09/05/Rust-1.81.0.html)) with the following changes affecting `fbsource`: * Feature stabilizations: * `io_slice_advance` ([#62726](rust-lang/rust#62726)) * `panic_info_message` ([#66745](rust-lang/rust#66745)) * `fs_try_exists` ([#83186](rust-lang/rust#83186)) * `lint_reasons` ([#120924](rust-lang/rust#120924)) * `duration_abs_diff` ([#117618](rust-lang/rust#117618)) * `effects` ([#102090](rust-lang/rust#102090)) * New `clippy` lints: * `manual_inspect` ([#12287](rust-lang/rust-clippy#12287)) * `manual_pattern_char_comparison` ([#12849](rust-lang/rust-clippy#12849)) * Other: * `NEVER_TYPE_FALLBACK_FLOWING_INTO_UNSAFE` became a deny-by-default lint ([#126881](rust-lang/rust#126881) & [#123748](rust-lang/rust#123748)) * Changes to `stringify!` introducing whitespaces between some tokens ([#125174](rust-lang/rust#125174)) * `format!` is now marked with a `must_use` hint ([#127355](rust-lang/rust#127355)) ignore-conflict-markers Reviewed By: zertosh, dtolnay Differential Revision: D63864870 fbshipit-source-id: c8d61f3e9483ec709c8116514cfb030c883ec262
1 parent 53c1895 commit 5bb1c5c

File tree

9 files changed

+15
-19
lines changed

9 files changed

+15
-19
lines changed

allocative/allocative/src/rc_str.rs

+1
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ use std::ops::Deref;
1414
use std::rc::Rc;
1515

1616
#[derive(Clone, Debug, PartialEq, Eq, Ord, PartialOrd)]
17+
#[allow(dead_code)]
1718
pub(crate) struct RcStr(Rc<str>);
1819

1920
impl<'a> From<&'a str> for RcStr {

gazebo/dupe/src/__macro_refs.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@
1212
use crate::Dupe;
1313

1414
#[inline]
15-
pub const fn assert_dupe<T: Dupe + ?Sized>() {}
15+
pub const fn assert_dupe<T: Dupe>() {}

starlark/src/tests/derive/freeze/basic.rs

+1
Original file line numberDiff line numberDiff line change
@@ -19,4 +19,5 @@ use crate as starlark;
1919
use crate::values::Freeze;
2020

2121
#[derive(Freeze)]
22+
#[allow(dead_code)]
2223
struct TestUnitStruct;

starlark/src/tests/uncategorized.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -956,7 +956,7 @@ fn test_fuzzer_59102() {
956956
let res: Result<AstModule, crate::Error> =
957957
AstModule::parse("hello_world.star", src.to_owned(), &Dialect::Standard);
958958
// The panic actually only happens when we format the result
959-
format!("{:?}", res);
959+
let _unused = format!("{:?}", res);
960960
}
961961

962962
#[test]
@@ -966,7 +966,7 @@ fn test_fuzzer_59371() {
966966
let res: Result<AstModule, crate::Error> =
967967
AstModule::parse("hello_world.star", src.to_owned(), &Dialect::Standard);
968968
// The panic actually only happens when we format the result
969-
format!("{:?}", res);
969+
let _unused = format!("{:?}", res);
970970
}
971971

972972
#[test]

starlark/src/values/error.rs

+2-5
Original file line numberDiff line numberDiff line change
@@ -100,10 +100,7 @@ impl ValueError {
100100

101101
/// Helper to create an [`OperationNotSupported`](ValueError::OperationNotSupported) error.
102102
#[cold]
103-
pub fn unsupported<'v, T, V: StarlarkValue<'v> + ?Sized>(
104-
_left: &V,
105-
op: &str,
106-
) -> crate::Result<T> {
103+
pub fn unsupported<'v, T, V: StarlarkValue<'v>>(_left: &V, op: &str) -> crate::Result<T> {
107104
Self::unsupported_owned(V::TYPE, op, None)
108105
}
109106

@@ -114,7 +111,7 @@ impl ValueError {
114111

115112
/// Helper to create an [`OperationNotSupported`](ValueError::OperationNotSupportedBinary) error.
116113
#[cold]
117-
pub fn unsupported_with<'v, T, V: StarlarkValue<'v> + ?Sized>(
114+
pub fn unsupported_with<'v, T, V: StarlarkValue<'v>>(
118115
_left: &V,
119116
op: &str,
120117
right: Value,

starlark/src/values/layout/vtable.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -134,9 +134,9 @@ pub(crate) struct AValueVTable {
134134
allocative: unsafe fn(StarlarkValueRawPtr) -> *const dyn Allocative,
135135
}
136136

137-
struct GetTypeId<'v, T: StarlarkValue<'v> + ?Sized>(PhantomData<&'v T>);
137+
struct GetTypeId<'v, T: StarlarkValue<'v>>(PhantomData<&'v T>);
138138

139-
impl<'v, T: StarlarkValue<'v> + ?Sized> GetTypeId<'v, T> {
139+
impl<'v, T: StarlarkValue<'v>> GetTypeId<'v, T> {
140140
const TYPE_ID: ConstTypeId = ConstTypeId::of::<<T as ProvidesStaticType>::StaticType>();
141141
const STARLARK_TYPE_ID: StarlarkTypeId = StarlarkTypeId::of::<T>();
142142
}

starlark/src/values/type_repr.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ impl<T: StarlarkTypeRepr> StarlarkTypeRepr for SetType<T> {
8282
}
8383
}
8484

85-
impl<'v, T: StarlarkValue<'v> + ?Sized> StarlarkTypeRepr for T {
85+
impl<'v, T: StarlarkValue<'v>> StarlarkTypeRepr for T {
8686
type Canonical = Self;
8787

8888
fn starlark_type_repr() -> Ty {

starlark/src/values/types/string/methods.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1093,7 +1093,7 @@ pub(crate) fn string_methods(builder: &mut MethodsBuilder) {
10931093
let mut s = this;
10941094
let mut lines: Vec<StringValue> = Vec::new();
10951095
loop {
1096-
if let Some(x) = s.find(|x| x == '\n' || x == '\r') {
1096+
if let Some(x) = s.find(['\n', '\r']) {
10971097
let y = x;
10981098
let x = match s.get(y..y + 2) {
10991099
Some("\r\n") => y + 2,

starlark/src/values/typing/type_compiled/compiled.rs

+4-7
Original file line numberDiff line numberDiff line change
@@ -350,13 +350,10 @@ impl<'v, V: ValueLike<'v>> Hash for TypeCompiled<V> {
350350
impl<'v, V: ValueLike<'v>> PartialEq for TypeCompiled<V> {
351351
#[allow(clippy::manual_unwrap_or)]
352352
fn eq(&self, other: &Self) -> bool {
353-
match self.0.to_value().equals(other.0.to_value()) {
354-
Ok(b) => b,
355-
Err(_) => {
356-
// Unreachable, but we should not panic in `PartialEq`.
357-
false
358-
}
359-
}
353+
self.0
354+
.to_value()
355+
.equals(other.0.to_value())
356+
.unwrap_or_default()
360357
}
361358
}
362359

0 commit comments

Comments
 (0)