cargo-count 0.2.4

Cargo subcommand for displaying statistics about projects, such as code, comments, and unsafe counters
1
2
3
4
5
6
7
8
9
10
11
/// Defines comment styles for any language
pub trait Comment {
    /// The type of the comment (`String`, `&'static str`, etc.)
    type Rep;
    /// Returns the single line comment style, if any
    fn single(&self) -> Option<Vec<<Self as Comment>::Rep>>;
    /// Returns the start of a multi-line comment style, if any
    fn multi_start(&self) -> Option<<Self as Comment>::Rep>;
    /// Returns the end of a multi-line comment style, if any
    fn multi_end(&self) -> Option<<Self as Comment>::Rep>;
}