question: living Cursive seems to locks std out
- Dominant language
- Rust
- Stars
- 4.8k
- Forks
- 270
- Avg merge
- 5d 19h
- Merged PRs (30d)
- 2
Description
Hi @gyscos
I'm new to Rust and I'm inspired by your work on Cursive :+1:
Can you help me understand why any new Cursice instance is blocking stdout ?
Here is two cases I compared :
```rust
extern crate cursive;
use cursive::Cursive;
use cursive::views::{Dialog, TextView};
fn main() {
println!("A");
let mut siv = Cursive::new();
println!("B");
siv.add_layer(
Dialog::around(TextView::new("Hello Dialog!"))
.title("Cursive")
.button("Quit", |s| s.quit()),
);
println!("C");
}
# $ cargo run
# A
```
Compared to
```rust
extern crate cursive;
use cursive::Cursive;
use cursive::views::{Dialog, TextView};
fn main() {
println!("A");
{
let mut siv = Cursive::new();
println!("B");
siv.add_layer(
Dialog::around(TextView::new("Hello Dialog!"))
.title("Cursive")
.button("Quit", |s| s.quit()),
);
}
println!("C");
}
# $ cargo run
# A
# C
```
Apparently as long as a Cursive instance is alive, we can't print to stdout.
Do I get it right ?
Thanks
Contributor guide
Assessment
This issue has not been assessed yet.