Adding support for stream_cast to the S3 stream wrapper. Closes #78