nickel-org / session Goto Github PK
View Code? Open in Web Editor NEWSession support for nickel applications
Session support for nickel applications
According to the src
folder in .cargo/registry
, [email protected]
is dependent on [email protected]
which is dependent on [email protected]
. Therefore, trying to cargo check
a project that relies on it will give the following error message :
error: enum is private and its variants cannot be re-exported
--> <cargo registry path>\mustache-0.6.3\src\parser.rs:4:9
|
4 | pub use self::ParserState::*;
| ^^^^^^^^^^^^^^^^^^^^
...
43 | enum ParserState { TEXT, OTAG, TAG, CTAG }
| ---------------- help: consider making the enum public: `pub enum ParserState`
error: enum is private and its variants cannot be re-exported
--> <cargo registry path>\mustache-0.6.3\src\parser.rs:5:9
|
5 | pub use self::TokenClass::*;
| ^^^^^^^^^^^^^^^^^^^
...
18 | enum TokenClass {
| --------------- help: consider making the enum public: `pub enum TokenClass`
Compiling gdi32-sys v0.2.0
error: aborting due to 2 previous errors
error: Could not compile `mustache`.
Modifying the dependency to [email protected]
should do the trick.
Information on my setup:
#rustc --version --verbose
rustc 1.32.0-nightly (4a45578bc 2018-12-07)
binary: rustc
commit-hash: 4a45578bc58ff262864f72680cc02e83f5d2f5b3
commit-date: 2018-12-07
host: x86_64-pc-windows-msvc
release: 1.32.0-nightly
LLVM version: 8.0
#cargo --version --verbose
cargo 1.32.0-nightly (5e85ba14a 2018-12-02)
release: 1.32.0
commit-hash: 5e85ba14aaa20f8133863373404cb0af69eeef2c
commit-date: 2018-12-02
router.get("/", middleware! { |req, mut response|
let mut data = HashMap::new();
let cook = format!("{:?}", CookieSession::get_mut(req, &mut response));
error[E0308]: mismatched types
--> src/handler.rs:24:57
|
24 | let cook = format!("{:?}", CookieSession::get_mut(req, &mut response));
| ^^^ expected struct `nickel::request::Request`, found struct `nickel::Request`
|
= note: expected type `&mut nickel::request::Request<'_, '_, _>`
= note: found type `&'r mut nickel::Request<'mw, 'conn, _>`
error[E0308]: mismatched types
--> src/handler.rs:24:62
|
24 | let cook = format!("{:?}", CookieSession::get_mut(req, &mut response));
| ^^^^^^^^^^^^^ expected struct `nickel::response::Response`, found struct `nickel::Response`
|
= note: expected type `&mut nickel::response::Response<'_, _>`
= note: found type `&mut nickel::Response<'mw, _>`
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.