-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
Hi,
In the following code, it will register the name and value into &self, which is an immut reference. Is it a violation of Rust's reference or designed behavior?
libucl-rs/libucl/src/parser.rs
Lines 108 to 114 in 30360ec
| pub fn register_var(&self, name: String, value: String) { | |
| let n = CString::new(name).unwrap(); | |
| let v = CString::new(value).unwrap(); | |
| unsafe { | |
| ucl_parser_register_variable(self.parser, n.as_ptr(), v.as_ptr()) | |
| } | |
| } |
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels