Commit Graph

141 Commits (ed248017b476f17334260db31daf82cc07c2a465)

Author SHA1 Message Date
dignifiedquire 5bf3d95313 feat: do not require default feature for unstable 5 years ago
Yoshua Wuyts dfb0c8124c
remove usage of deprecated method
Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>
5 years ago
k-nasa 43f4f393af fix missing export for the return value 5 years ago
Fenhl 07eb2c1280
Make WriteFmtFuture must_use
Fixes #627. Thanks to @jebrosen for pointing out the location of the issue.
5 years ago
Yoshua Wuyts 46cafffc31
Merge pull request #571 from killercup/more-errors
Add context to more errors
5 years ago
boats 0f30ab8c0a Fix the docs and Debug output of BufWriter. (#588)
The BufWriter docs inaccurately stated that it flushes on drop, which it does
not do. This PR changes the docs, as well as the example, to highlight that
the user must explicitly flush a bufwriter.

There were also two places where the BufWriter code referred to it as a
BufReader: in the link to the std docs, and in the Debug output. Those have
also been fixed.
5 years ago
Pascal Hertleif aa7d1c27a4
Verbose errors: Apply suggestions
Co-Authored-By: Yoshua Wuyts <yoshuawuyts+github@gmail.com>
5 years ago
Pascal Hertleif e01f07d72a Add context to more errors
cc #569
5 years ago
Yoshua Wuyts 77800ab3f9
Merge pull request #526 from yjhmelody/refactor-dir
refactor io dir to be same with std and export IntoInnerError
5 years ago
Pascal Hertleif c704643296 Remove verbose-errors cargo feature 5 years ago
Pascal Hertleif 99ddfb3f93 Wrap code more clearly in cfg blocks 5 years ago
Pascal Hertleif 8ce3e78952 verbose errors feature
This adds a new "verbose-errors" feature flag to async-std that enables
wrapping certain errors in structures with more context. As an example,
we use it in `fs::File::{open,create}` to add the given path to the
error message (something that is lacking in std to annoyance of many).
5 years ago
yjh 74caed2d4b
Update src/io/seek/mod.rs
Co-Authored-By: Taiki Endo <te316e89@gmail.com>
5 years ago
yjhmelody 76ec9c4563 update doc url 5 years ago
yjhmelody 5adb112a00 export IntoInnerError for io 5 years ago
yjhmelody 9d634cb2a7 refactor io dir to be same with std 5 years ago
Stjepan Glavina c2f750d288 Cleanup stream module 5 years ago
Stjepan Glavina 9e185f1c3e
Unstable feature: copy takes arguments by value (#471)
* Unstable feature: copy takes arguments by value

* Fix feature flags
5 years ago
Stjepan Glavina 548733e5d5
Cleanup stream traits (#487)
* Cleanup stream traits

* Fix docs
5 years ago
Yoshua Wuyts 335bd34470 Add "std" feature flag (#476)
* core feature

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>

* introduce std + default features

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>

* test std features on ci

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>

* finish up all features

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>

* Fix task_local macro

* Remove crossbeam-channel and futures-timer from std

* Move future::timeout() behind cfg_default
5 years ago
Yoshua Wuyts a064a5b13e
Merge pull request #459 from stjepang/expose-ext-traits
Expose extension traits in preludes
5 years ago
Stjepan Glavina 93b01e36ed
Clippy fixes (#462) 5 years ago
Stjepan Glavina a757cc02dc Expose extension traits in preludes 5 years ago
Stjepan Glavina 43bb59cd02 Fix some links in docs 5 years ago
Yoshua Wuyts 6f9436e575
mark stdio-lock structs as unstable
Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>
5 years ago
k-nasa 3dcad984b4 fix: To unstable feature 5 years ago
k-nasa 81873ae5f3 fix 5 years ago
k-nasa 0661f774c2 Merge branch 'master' into add_stdin_lock 5 years ago
Stjepan Glavina 3dd59d7056
Refactor the task module (#421)
* Refactor the task module

* Fix clippy warning

* Simplify task-local entries

* Reduce the amount of future wrapping

* Cleanup

* Simplify stealing
5 years ago
k-nasa caa23381f0 fix clippy warning 5 years ago
k-nasa eeb44c86e9 fix 5 years ago
k-nasa 2c91b30ee8 feat: Add Read and Write trait to Lock struct 5 years ago
k-nasa 35cb11e398 Merge branch 'master' into add_stdin_lock 5 years ago
Yoshua Wuyts 4475a229d6
backlink io docs
Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>
5 years ago
k-nasa 59615a655b feat: Add StderrLock and StdoutLock struct 5 years ago
k-nasa 48b255897e Merge branch 'master' into add_stdin_lock 5 years ago
Taiki Endo 2abf5ca891
Deny warnings on CI (#378)
* Deny warnings on CI

* Fix some clippy warnings
5 years ago
Taiki Endo 944e43d4bf Remove Pin API related unsafe code by using pin-project-lite cra… (#381) 5 years ago
Stjepan Glavina ec23632f3e
Cleanup: replace cfg-if with our macros (#361)
* Cleanup: replace cfg-if with our macros

* Prefix macros with cfg_

* Remove #[macro_export] from internal macros
5 years ago
k-nasa f2bf01223c $cargo fmt 5 years ago
k-nasa 70e8476264 fix StdinLock doc test 5 years ago
k-nasa a5a00d7b14 feat: Add StdinLock struct 5 years ago
Yoshua Wuyts d250eee556
port the std::io docs to async_std::io
Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>
5 years ago
Yoshua Wuyts 9f8fa45dc7
io docs
Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>
5 years ago
Yoshua Wuyts 49faea2023 init FutureExt (#308)
* init FutureExt

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>

* prelude

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>

* Refactor extension_trait

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>

* Fix rustdoc

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>
5 years ago
Yoshua Wuyts b4c1c63fd2
task::blocking async closure -> FnOnce
Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>
5 years ago
Yoshua Wuyts e938527f66 add stream::interval (#298)
* add stream::interval

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>

* fix tests

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>

* cargo fmt

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>

* cross-docs

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>

* update deps

Signed-off-by: Yoshua Wuyts <yoshuawuyts@gmail.com>
5 years ago
k-nasa 94ef3dc2b2 feat: Add Stdout::lock 5 years ago
k-nasa 9b09806593 feat: Add Stdin::lock 5 years ago
k-nasa f9741e7488 feat: Add Stderr::lock 5 years ago