resurect shootout-mandelbrot.rs

Changes:
* add licence;
* remove usage of libc and unsafe;
* use BufferedWriter to improve performance;
* use a DummyWriter to cancel binary output in test.
Clarrify the message for test mode and use u8 instead of i8 for storing bits
Prettier long string breaking.
auto merge of #10531 : TeXitoi/rust/mandelbrot-resurected, r=cmr

Changes:
* add licence;
* remove usage of libc and unsafe;
* use BufferedWriter to improve performance;
* use a DummyWriter to cancel binary output in test.