Skip to content

Commit

Permalink
update platform010 & platform010-aarch64 symlinks
Browse files Browse the repository at this point in the history
Summary: Upgrade to 1.82.0 with the minimal set of changes to keep everything building.

Reviewed By: dtolnay

Differential Revision: D65324129

fbshipit-source-id: 8266029f01dcc80dd78c169286b08707f36fc761
  • Loading branch information
capickett authored and facebook-github-bot committed Nov 13, 2024
1 parent 7fb06fb commit b187c5f
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 12 deletions.
24 changes: 12 additions & 12 deletions gazebo/src/ext/str.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ pub trait StrExt {
#[cfg(feature = "str_pattern_extensions")]
fn split1<'a, P>(&'a self, pat: P) -> (&'a Self, &'a Self)
where
P: Pattern<'a>;
P: Pattern;

/// Like `split`, but only separates off the first element if there is a
/// separator, otherwise returns `None`. For example:
Expand All @@ -48,7 +48,7 @@ pub trait StrExt {
#[deprecated(since = "0.6.1", note = "use `split_once` available in `std`")]
fn split1_opt<'a, P>(&'a self, pat: P) -> Option<(&'a Self, &'a Self)>
where
P: Pattern<'a>;
P: Pattern;

/// Trim off the first match, or return the string unchanged if the pattern
/// is not a prefix of the string. Like 'trim_start_matches', but at
Expand All @@ -63,7 +63,7 @@ pub trait StrExt {
#[cfg(feature = "str_pattern_extensions")]
fn trim_start_match<'a, P>(&'a self, pat: P) -> &'a Self
where
P: Pattern<'a>;
P: Pattern;

/// Trim off the first match and return 'Some', or return 'None' if the
/// pattern is not a prefix of the string. Like 'trim_start_matches'.
Expand All @@ -79,7 +79,7 @@ pub trait StrExt {
#[deprecated(note = "Use str.strip_prefix instead")]
fn trim_start_match_opt<'a, P>(&'a self, pat: P) -> Option<&'a Self>
where
P: Pattern<'a>;
P: Pattern;

/// Trim off the first match, or return the string unchanged if the pattern
/// is not a prefix of the string. Like 'trim_start_matches', but at
Expand All @@ -94,7 +94,7 @@ pub trait StrExt {
#[cfg(feature = "str_pattern_extensions")]
fn trim_end_match<'a, P>(&'a self, pat: P) -> &'a Self
where
P: Pattern<'a, Searcher: ReverseSearcher<'a>>;
P: Pattern<Searcher<'a>: ReverseSearcher<'a>>;

/// Trim off the first match and return 'Some', or return 'None' if the
/// pattern is not a prefix of the string. Like 'trim_start_matches'.
Expand All @@ -110,30 +110,30 @@ pub trait StrExt {
#[deprecated(note = "Use str.strip_suffix instead")]
fn trim_end_match_opt<'a, P>(&'a self, pat: P) -> Option<&'a Self>
where
P: Pattern<'a, Searcher: ReverseSearcher<'a>>;
P: Pattern<Searcher<'a>: ReverseSearcher<'a>>;
}

impl StrExt for str {
#[cfg(feature = "str_pattern_extensions")]
fn split1_opt<'a, P>(&'a self, pat: P) -> Option<(&'a Self, &'a Self)>
where
P: Pattern<'a>,
P: Pattern,
{
self.split_once(pat)
}

#[cfg(feature = "str_pattern_extensions")]
fn split1<'a, P>(&'a self, pat: P) -> (&'a Self, &'a Self)
where
P: Pattern<'a>,
P: Pattern,
{
self.split_once(pat).unwrap_or((self, ""))
}

#[cfg(feature = "str_pattern_extensions")]
fn trim_start_match_opt<'a, P>(&'a self, pat: P) -> Option<&'a Self>
where
P: Pattern<'a>,
P: Pattern,
{
let mut matcher = pat.into_searcher(self);
match matcher.next() {
Expand All @@ -145,7 +145,7 @@ impl StrExt for str {
#[cfg(feature = "str_pattern_extensions")]
fn trim_start_match<'a, P>(&'a self, pat: P) -> &'a Self
where
P: Pattern<'a>,
P: Pattern,
{
#[allow(deprecated)]
self.trim_start_match_opt(pat).unwrap_or(self)
Expand All @@ -154,7 +154,7 @@ impl StrExt for str {
#[cfg(feature = "str_pattern_extensions")]
fn trim_end_match_opt<'a, P>(&'a self, pat: P) -> Option<&'a Self>
where
P: Pattern<'a, Searcher: ReverseSearcher<'a>>,
P: Pattern<Searcher<'a>: ReverseSearcher<'a>>,
{
let mut matcher = pat.into_searcher(self);
match matcher.next_back() {
Expand All @@ -166,7 +166,7 @@ impl StrExt for str {
#[cfg(feature = "str_pattern_extensions")]
fn trim_end_match<'a, P>(&'a self, pat: P) -> &'a Self
where
P: Pattern<'a, Searcher: ReverseSearcher<'a>>,
P: Pattern<Searcher<'a>: ReverseSearcher<'a>>,
{
#[allow(deprecated)]
self.trim_end_match_opt(pat).unwrap_or(self)
Expand Down
1 change: 1 addition & 0 deletions gazebo/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
*/

#![cfg_attr(feature = "str_pattern_extensions", feature(pattern))]
#![allow(clippy::too_long_first_doc_paragraph)]

//! A collection of well-tested primitives that have been useful. Most modules stand alone.
Expand Down

0 comments on commit b187c5f

Please sign in to comment.