Skip to content

Commit

Permalink
Auto merge of #104387 - Manishearth:rollup-9e551p5, r=Manishearth
Browse files Browse the repository at this point in the history
Rollup of 9 pull requests

Successful merges:

 - #103709 (ci: Upgrade dist-x86_64-netbsd to NetBSD 9.0)
 - #103744 (Upgrade cc for working is_flag_supported on cross-compiles)
 - #104105 (llvm: dwo only emitted when object code emitted)
 - #104158 (Return .efi extension for EFI executable)
 - #104181 (Add a few known-bug tests)
 - #104266 (Regression test for coercion of mut-ref to dyn-star)
 - #104300 (Document `Path::parent` behavior around relative paths)
 - #104304 (Enable profiler in dist-s390x-linux)
 - #104362 (Add `delay_span_bug` to `AttrWrapper::take_for_recovery`)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
  • Loading branch information
bors committed Nov 14, 2022
2 parents 2e81036 + 2c2a882 commit e479c70
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
13 changes: 12 additions & 1 deletion std/src/path.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2142,7 +2142,10 @@ impl Path {

/// Returns the `Path` without its final component, if there is one.
///
/// Returns [`None`] if the path terminates in a root or prefix.
/// This means it returns `Some("")` for relative paths with one component.
///
/// Returns [`None`] if the path terminates in a root or prefix, or if it's
/// the empty string.
///
/// # Examples
///
Expand All @@ -2156,6 +2159,14 @@ impl Path {
/// let grand_parent = parent.parent().unwrap();
/// assert_eq!(grand_parent, Path::new("/"));
/// assert_eq!(grand_parent.parent(), None);
///
/// let relative_path = Path::new("foo/bar");
/// let parent = relative_path.parent();
/// assert_eq!(parent, Some(Path::new("foo")));
/// let grand_parent = parent.and_then(Path::parent);
/// assert_eq!(grand_parent, Some(Path::new("")));
/// let great_grand_parent = grand_parent.and_then(Path::parent);
/// assert_eq!(great_grand_parent, None);
/// ```
#[stable(feature = "rust1", since = "1.0.0")]
#[doc(alias = "dirname")]
Expand Down
2 changes: 1 addition & 1 deletion unwind/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ compiler_builtins = "0.1.0"
cfg-if = "1.0"

[build-dependencies]
cc = "1.0.69"
cc = "1.0.76"

[features]

Expand Down

0 comments on commit e479c70

Please sign in to comment.