Open
Description
It looks like bindgen
sees a doc-comment for a particular enum variant then keeps using the same doc-comment for every variant afterwards, instead of just the variant being documented.
Input C/C++ Header
typedef enum parameter_t {
speed,
acceleration,
/// The amount of backlash in the system.
backlash,
desired_speed,
position,
desired_position,
} parameter_t;
Bindgen Invocation
$ bindgen input.h
Actual Results
pub const parameter_t_speed: parameter_t = 0;
pub const parameter_t_acceleration: parameter_t = 1;
/// The amount of backlash in the system.
pub const parameter_t_backlash: parameter_t = 2;
/// The amount of backlash in the system.
pub const parameter_t_desired_speed: parameter_t = 3;
/// The amount of backlash in the system.
pub const parameter_t_position: parameter_t = 4;
/// The amount of backlash in the system.
pub const parameter_t_desired_position: parameter_t = 5;
pub type parameter_t = i32;
Expected Results
pub const parameter_t_speed: parameter_t = 0;
pub const parameter_t_acceleration: parameter_t = 1;
/// The amount of backlash in the system.
pub const parameter_t_backlash: parameter_t = 2;
pub const parameter_t_desired_speed: parameter_t = 3;
pub const parameter_t_position: parameter_t = 4;
pub const parameter_t_desired_position: parameter_t = 5;
pub type parameter_t = i32;