You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using LM_Assemble and LM_Disassemble to automatically update jmp instruction operands, but there's no way to access the internal properties of lm_inst_t.
At the moment, to get the assembly string, I'm having to to_string the result of LM_Disassemble, split by " ->", and grab the first item in the array.
Would it be reasonable to make the properties of lm_inst_t public, or to provide functions to get access to the mnemonic, op_str, etc?
The fields in the structs are not public because the Rust wrapper needs to do convertions between C strings and Rust strings, for example. I probably just forgot to do it at the time.
The newer bindings will separate further the C API from the Rust API, where there will be a crate called libmem-sys (raw C bindings) and just libmem which will be more rusty
Those bindings are not complete yet, but when 5.0.0 releases, you should expect to be able to access them normally.
For the time being, best option might be to do functions like this in a fork:
I'm using LM_Assemble and LM_Disassemble to automatically update jmp instruction operands, but there's no way to access the internal properties of
lm_inst_t
.At the moment, to get the assembly string, I'm having to to_string the result of LM_Disassemble, split by
" ->"
, and grab the first item in the array.Would it be reasonable to make the properties of
lm_inst_t
public, or to provide functions to get access to the mnemonic, op_str, etc?using
libmem = { git = "https://github.com/rdbo/libmem.git", rev = "70745c82453e9ea38d289ff02c4dfc324df5c1ec" }
The text was updated successfully, but these errors were encountered: