Skip to content

Commit

Permalink
add comments for greater_than and less_than
Browse files Browse the repository at this point in the history
  • Loading branch information
tomoikey committed Oct 29, 2024
1 parent 20db218 commit 2beb45e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/rule/number/greater.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
macro_rules! define_greater_rule {
($t: ty) => {
$crate::paste::item! {
/// A type that holds a value satisfying the `GreaterRule`
pub type [<Greater $t:camel>]<const THAN: $t> = $crate::Refined<[<GreaterRule $t:camel>]<THAN>>;

/// Rule where the target value must be greater than `THAN`
#[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord)]
pub struct [<GreaterRule $t:camel>]<const THAN: $t>;

Expand Down
2 changes: 2 additions & 0 deletions src/rule/number/less.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
macro_rules! define_less_rule {
($t: ty) => {
$crate::paste::item! {
/// A type that holds a value satisfying the `LessRule`
pub type [<Less $t:camel>]<const THAN: $t> = $crate::Refined<[<LessRule $t:camel>]<THAN>>;

/// Rule where the target value must be less than `THAN`
#[derive(Debug, Clone, Copy, PartialEq, Eq, PartialOrd, Ord)]
pub struct [<LessRule $t:camel>]<const THAN: $t>;

Expand Down

0 comments on commit 2beb45e

Please sign in to comment.