-
Notifications
You must be signed in to change notification settings - Fork 224
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
The scope of the unsafe block can be appropriately reduced #273
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you please fix up the formatting on these changes?
} | ||
let p: *mut u8 = result.as_mut_ptr() as *mut u8; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the indentation is wrong here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
see #305
@@ -2727,16 +2727,16 @@ impl <'a> PointerBuilder<'a> { | |||
wire_helpers::set_struct_pointer( | |||
self.arena, | |||
self.segment_id, self.cap_table, self.pointer, *value, canonicalize)?; | |||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
indentation
} | ||
|
||
pub fn set_list(&self, value: &ListReader, canonicalize: bool) -> Result<()> { | ||
unsafe { | ||
wire_helpers::set_list_pointer(self.arena, self.segment_id, | ||
self.cap_table, self.pointer, *value, canonicalize)?; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
indentation
@@ -3102,33 +3102,33 @@ impl <'a> StructBuilder<'a> { | |||
return Ok(()) | |||
} | |||
|
|||
unsafe { | |||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we remove this unsafe
block then the following lines should be less indented.
No description provided.