This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """A quick benchmark comparing default and explicit-value initialization for | |
| various dataclass-like libraries. | |
| We also compare against the time it takes to initialize a `dict` or `tuple` | |
| with the same data, as a "low-bar" for pure-python implementations. | |
| These are not semantically identical operations: notably, Pydantic validates | |
| and may coerce supplied values while the other constructors generally assign them. | |
| """ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /target | |
| /db | |
| /Cargo.lock |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #![feature(scoped_tls)] | |
| #[macro_use] extern crate nickel; | |
| use nickel::Nickel; | |
| use nickel::router::http_router::HttpRouter; | |
| use nickel::ResponseFinalizer; | |
| struct MyObject; | |
| impl MyObject { |