Update the sample code in README.md.

This change makes the sample code compilable with the latest rustc.