summaryrefslogtreecommitdiff
path: root/src/snapshot.rs
blob: fa7837ede857aab66884bcd7ac10e6fb09cd7a2d (plain)
1
2
3
4
5
6
7
8
9
// Copyright 2018 the Deno authors. All rights reserved. MIT license.
use libdeno::deno_buf;

pub fn deno_snapshot() -> deno_buf {
  let data =
    include_bytes!(concat!(env!("GN_OUT_DIR"), "/gen/snapshot_deno.bin"));

  unsafe { deno_buf::from_raw_parts(data.as_ptr(), data.len()) }
}