Use lazy_static to cache datetime formats
One of those two date formats was re-compiled before any date was displayed. Now they are compiled only the first time they're used, and cached versions are used thereafter, resulting in a speedup.
Showing
... | ... | @@ -11,12 +11,13 @@ ansi_term = "0.7.0" |
bitflags = "0.1" | ||
datetime = "0.4.1" | ||
getopts = "0.2.14" | ||
lazy_static = "0.1.*" | ||
libc = "0.2.0" | ||
locale = "0.1.2" | ||
natord = "1.0.7" | ||
num_cpus = "0.2.7" | ||
number_prefix = "0.2.3" | ||
scoped_threadpool = "*" | ||
scoped_threadpool = "0.1.*" | ||
term_grid = "0.1.2" | ||
unicode-width = "0.1.3" | ||
users = "0.4.3" | ||
... | ... |
想要评论请 注册 或 登录