chris-morgan / rust-http

Completely OBSOLETE Rust HTTP library (server and client)
Other
390 stars 110 forks source link

mod.rs has unwrap() problem #163

Closed iamblue closed 10 years ago

iamblue commented 10 years ago

Running rustc src/http/lib.rs --crate-name http --crate-type lib -g -C metadata=b27c1e7938f5a5d0 -C extra-filename=-b27c1e7938f5a5d0 --out-dir /Users/blue-mtk/mtk/nickel/target/deps --dep-info /Users/blue-mtk/mtk/nickel/target/.fingerprint/http-b27c1e7938f5a5d0/dep-lib-http -L /Users/blue-mtk/mtk/nickel/target/deps -L /Users/blue-mtk/mtk/nickel/target/deps -L /Users/blue-mtk/mtk/nickel/target/native/http-b27c1e7938f5a5d0 --extern openssl=/Users/blue-mtk/mtk/nickel/target/deps/libopenssl-fbe75530f7eda428.rlib --extern url=/Users/blue-mtk/mtk/nickel/target/deps/liburl-921578b148f50e06.rlib src/http/headers/mod.rs:733:55: 733:63 error: type collections::string::String does not implement any method in scope named unwrap src/http/headers/mod.rs:733 self.to_utc().strftime("%a, %d %b %Y %T GMT").unwrap()

error: aborting due to previous error Could not compile http.

iamblue commented 10 years ago

my rust version is Nightly.

reem commented 10 years ago

@iamblue Can we get the output of rustc -v? This compiles cleanly for me with rustc 0.13.0-nightly (c46812f65 2014-10-19 00:47:18 +0000).

It's very possible your version of rust is outdated.

iamblue commented 10 years ago

my version is rustc 0.12.0-nightly (136ab3c6b 2014-10-04 00:17:04 +0000)

iamblue commented 10 years ago

@reem , I upgrade my rust version to rustc 0.13.0-nightly (c46812f65 2014-10-19 00:47:18 +0000) and solved this problem , thx !