Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename deno.argv, libdeno::DenoC and deno_set_flags #796

Merged
merged 8 commits into from
Sep 22, 2018
Merged

Conversation

ztplz
Copy link
Contributor

@ztplz ztplz commented Sep 22, 2018

#793 rename deno.argv to deno.args
#792 rename libdeno::DenoC to libdeno::isolate
#791 rename deno_set_flags to deno_set_v8_flags

Copy link
Member

@ry ry left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! Thank you. Just one comment...

src/libdeno.rs Outdated
pub fn deno_last_exception(d: *const isolate) -> *const c_char;
pub fn deno_get_data(d: *const isolate) -> *const c_void;
pub fn deno_set_response(d: *const isolate, buf: deno_buf);
pub fn deno_send(d: *const isolate, buf: deno_buf);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Many of these functions use the parameter name d for *const isolate. It would be better to rename this to either i or isolate_ptr.

src/handlers.rs Outdated
@@ -265,7 +265,7 @@ fn handle_code_cache(d: *const isolate, base: &msg::Base) -> Box<Op> {
}()))
}

fn handle_set_env(d: *const isolate, base: &msg::Base) -> Box<Op> {
fn handle_set_env(d: *const isolate_ptr, base: &msg::Base) -> Box<Op> {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I meant the parameter name, not the type.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure, I got it.

src/isolate.rs Outdated
@@ -76,7 +76,7 @@ impl Drop for Isolate {
}
}

pub fn from_c<'a>(d: *const libdeno::DenoC) -> &'a mut Isolate {
pub fn from_c<'a>(d: *const libdeno::isolate) -> &'a mut Isolate {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here too s/d/i/

Copy link
Member

@ry ry left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM - thanks!

@ry ry merged commit f3684c2 into denoland:master Sep 22, 2018
@ztplz ztplz deleted the rename branch September 30, 2018 19:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants