diff options
author | Andy Hayden <andyhayden1@gmail.com> | 2018-11-04 22:21:21 -0800 |
---|---|---|
committer | Ryan Dahl <ry@tinyclouds.org> | 2018-11-06 06:43:02 -0800 |
commit | 13e1eb2b87c146a8594e7e6f24ba738bff116246 (patch) | |
tree | 9b7c8f8adc012073d728f2412ffe41c8ffe8a59b /src/version.rs | |
parent | f477b45a0a398e379ecafd2525c460f2793a43c2 (diff) |
Fix many of the clippy::pedantic warnings
Diffstat (limited to 'src/version.rs')
-rw-r--r-- | src/version.rs | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/version.rs b/src/version.rs index ce95601de..19e673ca6 100644 --- a/src/version.rs +++ b/src/version.rs @@ -2,11 +2,10 @@ use libdeno; use std::ffi::CStr; -// Both the verson in Cargo.toml and this string must be kept in sync. -pub const DENO_VERSION: &str = "0.1.11"; +pub const DENO: &str = "0.1.11"; -pub fn get_v8_version() -> &'static str { - let v = unsafe { libdeno::deno_v8_version() }; - let c_str = unsafe { CStr::from_ptr(v) }; +pub fn v8() -> &'static str { + let version = unsafe { libdeno::deno_v8_version() }; + let c_str = unsafe { CStr::from_ptr(version) }; c_str.to_str().unwrap() } |