blob: 03b7d3c04d8953c4faa9771fc740f762f2f42c00 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
// Copyright 2018 the Deno authors. All rights reserved. MIT license.
use libdeno;
use std::ffi::CStr;
// TODO Extract this version string from Cargo.toml.
pub const DENO: &str = "0.2.0";
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()
}
|