112a9d9c8Sopenharmony_ci# Preventing the Derivation of `Debug`
212a9d9c8Sopenharmony_ci
312a9d9c8Sopenharmony_ci`bindgen` will attempt to derive the `Debug` traits on a best-effort
412a9d9c8Sopenharmony_cibasis. Sometimes, it might not understand that although adding `#[derive(Debug)]` to a translated type definition will compile, it still shouldn't do
512a9d9c8Sopenharmony_cithat for reasons it can't know. In these cases, the `nodebug` annotation can be
612a9d9c8Sopenharmony_ciused to prevent bindgen to autoderive the `Debug` traits for a type.
712a9d9c8Sopenharmony_ci
812a9d9c8Sopenharmony_ci### Library
912a9d9c8Sopenharmony_ci
1012a9d9c8Sopenharmony_ci* [`bindgen::Builder::no_debug`](https://docs.rs/bindgen/latest/bindgen/struct.Builder.html#method.no_debug)
1112a9d9c8Sopenharmony_ci
1212a9d9c8Sopenharmony_ci### Command Line
1312a9d9c8Sopenharmony_ci
1412a9d9c8Sopenharmony_ci* `--no-debug <regex>`
1512a9d9c8Sopenharmony_ci
1612a9d9c8Sopenharmony_ci### Annotations
1712a9d9c8Sopenharmony_ci
1812a9d9c8Sopenharmony_ci```c
1912a9d9c8Sopenharmony_ci/**
2012a9d9c8Sopenharmony_ci * Although bindgen can't know, this enum is not safe to format the output.
2112a9d9c8Sopenharmony_ci * the value may be combined with multiple bits in many C/C++ cases,
2212a9d9c8Sopenharmony_ci * for example:
2312a9d9c8Sopenharmony_ci *
2412a9d9c8Sopenharmony_ci * <div rustbindgen nodebug></div>
2512a9d9c8Sopenharmony_ci */
2612a9d9c8Sopenharmony_cienum AVRounding {
2712a9d9c8Sopenharmony_ci    AV_ROUND_ZERO     = 0,
2812a9d9c8Sopenharmony_ci    AV_ROUND_INF      = 1,
2912a9d9c8Sopenharmony_ci    AV_ROUND_DOWN     = 2,
3012a9d9c8Sopenharmony_ci    AV_ROUND_UP       = 3,
3112a9d9c8Sopenharmony_ci    AV_ROUND_NEAR_INF = 5,
3212a9d9c8Sopenharmony_ci    AV_ROUND_PASS_MINMAX = 8192,
3312a9d9c8Sopenharmony_ci};
3412a9d9c8Sopenharmony_ci
3512a9d9c8Sopenharmony_ci// Prototype
3612a9d9c8Sopenharmony_ciint64_t av_rescale_rnd(int64_t a, int64_t b, int64_t c, enum AVRounding) av_const;
3712a9d9c8Sopenharmony_ci
3812a9d9c8Sopenharmony_ci// Call
3912a9d9c8Sopenharmony_ciint64_t pts = av_rescale_rnd(40000, 3600, 90000, AV_ROUND_NEAR_INF | AV_ROUND_PASS_MINMAX);
4012a9d9c8Sopenharmony_ci```
41