diff options
author | 2020-10-14 10:47:08 +0000 | |
---|---|---|
committer | 2020-10-14 10:47:08 +0000 | |
commit | 55d67fad459aac4d9f14571f305a8983f36138cb (patch) | |
tree | dd59b1f1eec5f8a5038ec4b34fc0e94982c9cc0c /cortex-m-semihosting/src/export.rs | |
parent | 432e5f527430394570d1d07454e26cc41d5b2936 (diff) | |
parent | 320881e0b57d16a4f768a7c8543571e26113e904 (diff) | |
download | cortex-m-55d67fad459aac4d9f14571f305a8983f36138cb.tar.gz cortex-m-55d67fad459aac4d9f14571f305a8983f36138cb.tar.zst cortex-m-55d67fad459aac4d9f14571f305a8983f36138cb.zip |
Merge #269
269: Merge HStdout and HStderr into the same type r=jonas-schievink a=adamgreig
As the next step in https://github.com/rust-embedded/cortex-m/pull/263#pullrequestreview-495095345, this PR applies https://github.com/rust-embedded/cortex-m-semihosting/pull/41 to this repository.
@m-ou-se, I tried exporting a patch from cortex-m-semihosting and applying it here but it didn't work first time, so I ended up just copying the changes. I've set you as the author of the commit and marked it as committed-by me, I hope you're OK with that but please let me know if you'd like it changed. (Also, thanks again for the PR, sorry it's taken over a year...).
Co-authored-by: Mara Bos <m-ou.se@m-ou.se>
Diffstat (limited to 'cortex-m-semihosting/src/export.rs')
-rw-r--r-- | cortex-m-semihosting/src/export.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cortex-m-semihosting/src/export.rs b/cortex-m-semihosting/src/export.rs index c188ab0..0bbd09f 100644 --- a/cortex-m-semihosting/src/export.rs +++ b/cortex-m-semihosting/src/export.rs @@ -4,9 +4,9 @@ use core::fmt::{self, Write}; use cortex_m::interrupt; -use crate::hio::{self, HStderr, HStdout}; +use crate::hio::{self, HostStream}; -static mut HSTDOUT: Option<HStdout> = None; +static mut HSTDOUT: Option<HostStream> = None; pub fn hstdout_str(s: &str) { let _result = interrupt::free(|_| unsafe { @@ -28,7 +28,7 @@ pub fn hstdout_fmt(args: fmt::Arguments) { }); } -static mut HSTDERR: Option<HStderr> = None; +static mut HSTDERR: Option<HostStream> = None; pub fn hstderr_str(s: &str) { let _result = interrupt::free(|_| unsafe { |