Add documentation for Attr::is_doc_comment
This commit is contained in:
parent
e7c7aa7288
commit
88fa621bab
@ -232,6 +232,8 @@ impl AttrItem {
|
||||
}
|
||||
|
||||
impl Attribute {
|
||||
/// Returns `true` if it is a sugared doc comment (`///` or `//!` for example).
|
||||
/// So `#[doc = "doc"]` will return `false`.
|
||||
pub fn is_doc_comment(&self) -> bool {
|
||||
match self.kind {
|
||||
AttrKind::Normal(..) => false,
|
||||
|
Loading…
x
Reference in New Issue
Block a user