rust/tests/rustdoc-js/non-english-identifier.rs
2024-06-07 05:49:46 +08:00

48 lines
1004 B
Rust

#[doc(alias = "加法")]
pub fn add(left: usize, right: usize) -> usize {
left + right
}
pub fn API(left: usize, right: usize) -> usize {
left + right
}
#[macro_export]
macro_rules! {
($left:expr, $right:expr) => {
($left) + ($right)
};
}
#[doc(alias = "加法")]
#[macro_export]
macro_rules! add {
($left:expr, $right:expr) => {
($left) + ($right)
};
}
/// Add
pub trait <> {
type ;
fn (self, : ) -> Self::;
}
/// IntoIterator
pub trait {
type ;
type : Iterator<Item = Self::>;
fn (self) -> Self::;
}
pub type <> = Option<>;
/// "sum"
pub fn <, >(: ) -> <::>
where
: < = >,
: <, = >,
{
.().reduce(|, | .())
}