6 releases

0.4.2 May 30, 2023
0.4.1 May 21, 2023
0.4.0 Apr 4, 2023
0.3.1 Feb 28, 2023
0.2.2 Jan 5, 2023

#58 in FFI

Download history 24900/week @ 2025-02-04 26534/week @ 2025-02-11 19149/week @ 2025-02-18 21701/week @ 2025-02-25 21105/week @ 2025-03-04 25255/week @ 2025-03-11 23510/week @ 2025-03-18 26518/week @ 2025-03-25 25511/week @ 2025-04-01 23727/week @ 2025-04-08 19743/week @ 2025-04-15 19573/week @ 2025-04-22 18650/week @ 2025-04-29 17211/week @ 2025-05-06 16923/week @ 2025-05-13 16161/week @ 2025-05-20

71,894 downloads per month
Used in 58 crates (12 directly)

BSD-3-Clause

51KB
1.5K SLoC

Simple Doxygen to Rustdoc translation.

Provides a simple and straightforward API to translate raw Doxygen comments to Rustdoc comments. Purely experimental right now, maybe practical in a future?

Examples

use doxygen_rs::transform;

let rustdoc = transform("@brief Example Doxygen brief");
assert_eq!(rustdoc, "Example Doxygen brief");

Usage with bindgen >= 0.63

#[derive(Debug)]
struct Cb;

impl ParseCallbacks for Cb {
    fn process_comment(&self, comment: &str) -> Option<String> {
        Some(doxygen_rs::transform(comment))
    }
}

doxygen-rs

Transform Doxygen to Rustdoc.

Docs available here

Installation

Add this to your Cargo.toml

[dependencies]
doxygen-rs = "0.4"

Usage with Bindgen

Available on >=0.63 bindgen

#[derive(Debug)]
struct Cb;

impl ParseCallbacks for Cb {
    fn process_comment(&self, comment: &str) -> Option<String> {
        Some(doxygen_rs::transform(comment))
    }
}

Example

use doxygen_rs::transform;

let rustdoc = transform("@brief Example Doxygen brief");
assert_eq!(rustdoc, "Example Doxygen brief\n\n");

Dependencies

~0.6–1MB
~23K SLoC