| Age | Commit message (Collapse) | Author | Lines |
|
This is needed to derive Clone for types containing Durations.
|
|
* Fix `LimitReader`'s `Buffer::consume` impl to avoid limit underflow
* Make `MultiWriter` fail fast instead of always running through each
`Writer`. This may or may not be what we want, but it at least
doesn't throw any errors encountered in later `Writer`s into oblivion.
* Prevent `IterReader`'s `Reader::read` impl from returning EOF if given
an empty buffer.
[breaking-change]
|
|
Using "win32" to mean "Windows" is confusing, especially now, that Rust supports win64 builds.
Let's call spade a spade.
|
|
This implements some of the recommendations from https://github.com/rust-lang/meeting-minutes/blob/master/Meeting-API-review-2014-08-06.md.
Explanation in commits.
|
|
|
|
|
|
|
|
These all expose the underlying data representation and are
not the most convenient way of instantiation anyway.
|
|
|
|
[breaking-change]
|
|
|
|
Put `Duration` in `time::duration`, where the two constants can
be called just `MAX` and `MIN`. Reexport from `time`.
This provides more room for the time module to expand.
|
|
This is only breaking if you were previously specifying a duration
of zero for some mysterious reason.
[breaking-change]
|
|
[breaking-change]
|
|
Add tests. Also fix a bunch of broken time tests.
|
|
|
|
This is a workaround for having to write `Zero::zero` and will
be solved at the language level someday.
|
|
|
|
|
|
From rust-chrono 4f34003e03e259bd5cbda0cb4d35325861307cc6
|
|
|
|
|
|
Rename io::timer::sleep, Timer::sleep, Timer::oneshot,
Timer::periodic, to sleep_ms, oneshot_ms, periodic_ms. These functions
all take an integer and interpret it as milliseconds.
Replacement functions will be added that take Duration.
[breaking-change]
|
|
Taken from rust-chrono[1]. Needed for timers per #11189.
Experimental.
[1]: https://github.com/lifthrasiir/rust-chrono
|
|
This is in the prelude and won't break much code.
[breaking-change]
|
|
This required some contortions because importing both raw::Slice
and slice::Slice makes rustc crash.
Since `Slice` is in the prelude, this renaming is unlikely to
casue breakage.
[breaking-change]
|
|
ImmutableVector -> ImmutableSlice
ImmutableEqVector -> ImmutableEqSlice
ImmutableOrdVector -> ImmutableOrdSlice
MutableVector -> MutableSlice
MutableVectorAllocating -> MutableSliceAllocating
MutableCloneableVector -> MutableCloneableSlice
MutableOrdVector -> MutableOrdSlice
These are all in the prelude so most code will not break.
[breaking-change]
|
|
* The caller should be responsible for cleaning up file descriptors
* If a caller safely creates a file descriptor (via
native::io::file::open) the returned structure (FileDesc) will try to
clean up the file, failing in the process and writing error messages
to the screen.
* This should not happen as the caller has no public interface for
telling the FileDesc structure to NOT free the underlying fd.
* Alternatively, if another file is opened under the same fd held by
the FileDesc structure returned by native::io::file::open, it will
close the wrong file upon destruction.
|
|
|
|
Implement `Index` for `RingBuf`, `HashMap`, `TreeMap`, `SmallIntMap`, and `TrieMap`.
If there’s anything that I missed or should be removed, let me know.
|
|
This also deprecates HashMap::get. Use indexing instead.
|
|
The fail macro defines some function/static items internally, which got
a dead_code warning when `fail!()` is used inside a dead function. This
is ugly and unnecessarily reveals implementation details, so the
warnings can be squashed.
Fixes #16192.
|
|
This requires avoiding `quote_...!` for constructing the parts of the
__test module, since that stringifies and reinterns the idents, losing
the special gensym'd nature of them. (#15962.)
|
|
default entrypoint of the --test binary.
This allows one to, e.g., run tests under libgreen by starting it
manually, passing in the test entrypoint.
|
|
|
|
Several of the tests in `make check-fast` were failing so this fixes those tests.
|
|
|
|
Fix typo. It's possible it's `These modules` but I think it's supposed to be singular because it's not refering to nested modules.
|
|
|
|
This leaves the `Share` trait at `std::kinds` via a `#[deprecated]` `pub use`
statement, but the `NoShare` struct is no longer part of `std::kinds::marker`
due to #12660 (the build cannot bootstrap otherwise).
All code referencing the `Share` trait should now reference the `Sync` trait,
and all code referencing the `NoShare` type should now reference the `NoSync`
type. The functionality and meaning of this trait have not changed, only the
naming.
Closes #16281
[breaking-change]
|
|
|
|
This leaves the `Share` trait at `std::kinds` via a `#[deprecated]` `pub use`
statement, but the `NoShare` struct is no longer part of `std::kinds::marker`
due to #12660 (the build cannot bootstrap otherwise).
All code referencing the `Share` trait should now reference the `Sync` trait,
and all code referencing the `NoShare` type should now reference the `NoSync`
type. The functionality and meaning of this trait have not changed, only the
naming.
Closes #16281
[breaking-change]
|
|
Signed-off-by: Peter Atashian <retep998@gmail.com>
|
|
|
|
This replaces many instances chars being casted to u8 with byte literals.
|
|
|
|
This commit stabilizes the `std::sync::atomics` module, renaming it to
`std::sync::atomic` to match library precedent elsewhere, and tightening
up behavior around incorrect memory ordering annotations.
The vast majority of the module is now `stable`. However, the
`AtomicOption` type has been deprecated, since it is essentially unused
and is not truly a primitive atomic type. It will eventually be replaced
by a higher-level abstraction like MVars.
Due to deprecations, this is a:
[breaking-change]
|
|
|
|
Apparently the units are in milliseconds, not in seconds!
|
|
|