1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2024-11-21 15:04:11 -05:00

Minor libdeno clean ups.

This commit is contained in:
Ryan Dahl 2018-06-10 14:34:59 +02:00
parent 44e419065a
commit 041e503838
4 changed files with 5 additions and 10 deletions

View file

@ -262,9 +262,9 @@ void deno_init() {
v8::V8::Initialize();
}
const char* v8_version() { return v8::V8::GetVersion(); }
const char* deno_v8_version() { return v8::V8::GetVersion(); }
void v8_set_flags(int* argc, char** argv) {
void deno_set_flags(int* argc, char** argv) {
v8::V8::SetFlagsFromCommandLine(argc, argv, true);
}

View file

@ -18,10 +18,7 @@ namespace deno {
Deno* NewFromSnapshot(void* data, RecvCallback cb) {
auto natives_blob = *StartupBlob_natives();
printf("natives_blob %d bytes\n", natives_blob.raw_size);
auto snapshot_blob = *StartupBlob_snapshot();
printf("snapshot_blob %d bytes\n", snapshot_blob.raw_size);
v8::V8::SetNativesDataBlob(&natives_blob);
v8::V8::SetSnapshotDataBlob(&snapshot_blob);

View file

@ -21,14 +21,12 @@ typedef struct deno_s Deno;
typedef deno_buf (*RecvCallback)(Deno* d, deno_buf buf);
void deno_init();
const char* v8_version();
void v8_set_flags(int* argc, char** argv);
const char* deno_v8_version();
void deno_set_flags(int* argc, char** argv);
// Constructor
Deno* deno_new(void* data, RecvCallback cb);
void* deno_get_data();
// Returns nonzero on error.
// Get error text with deno_last_exception().
int deno_load(Deno* d, const char* name_s, const char* source_s);

View file

@ -31,7 +31,7 @@ class StartupDataCppWriter {
printf("Unable to open file \"%s\" for writing.\n", filename_);
exit(1);
}
printf("Wrote %s %d %s \n", name_, sd_.raw_size, filename_);
// printf("Wrote %s %d %s \n", name_, sd_.raw_size, filename_);
}
private: