You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Posix pahs like "/foo//bar" should be normalized to "/foo/bar". (WIndows likely has similar issues). Here is a test case:
// rustc --test normalize.rs && ./normalize
use std;
use Path = path::Path;
macro_rules! assert_equal (($expected: expr, $actual: expr) =>
{
let a = $actual; // only evaluate the expressions once
let e = $expected;
if a != e
{
fail fmt!("Found '%?', but expected '%?'", a, e);
}
})
// TODO: add a windows version of this
#[cfg(unix)]
fn root() -> Path
{
path::from_str(~"/tmp/")
}
#[test]
fn tester()
{
let path = root();
let path = path.push("/hmm");
let path = path.normalize();
assert_equal!(~"/tmp/hmm", path.to_str());
}
The text was updated successfully, but these errors were encountered:
identity_op: allow `1 << 0`
I went for accepting `1 << 0` verbatim instead of something more general as it seems to be what everyone in the issue thread needed.
changelog: identity_op: allow `1 << 0` as it's a common pattern in bit manipulation code.
Fixesrust-lang#3430
bors
pushed a commit
to rust-lang-ci/rust
that referenced
this issue
May 15, 2021
make some doc comments not doc tests
`./miri test --doc` will run doctests even if we have them disabled (that's a cargo quirk: rust-lang/cargo#13668). This fixes that command to not fail.
Posix pahs like "/foo//bar" should be normalized to "/foo/bar". (WIndows likely has similar issues). Here is a test case:
The text was updated successfully, but these errors were encountered: