Skip to content

Commit

Permalink
Reorder methods in CharMatcher.
Browse files Browse the repository at this point in the history
  • Loading branch information
renggli committed Dec 1, 2023
1 parent 13fca96 commit 615d824
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions lib/src/char_matcher/char_matcher.dart
Original file line number Diff line number Diff line change
Expand Up @@ -134,18 +134,18 @@ abstract class CharMatcher with ToStringPrinter implements Pattern {
_ => ConjunctiveCharMatcher([this, other])
};

/// Determines if the given Unicode code-point `value` belongs to this
/// character class. See [match] for details.
@nonVirtual
bool call(int value) => match(value);

/// Determines if the given Unicode code-point `value` belongs to this
/// character class.
///
/// The behavior is undefined if the value is outside of the valid unicode
/// code range.
bool match(int value);

/// Determines if the given Unicode code-point `value` belongs to this
/// character class. See [match] for details.
@nonVirtual
bool call(int value) => match(value);

/// Returns `true` if the [sequence] contains only matching characters.
bool everyOf(String sequence) => sequence.runes.every(match);

Expand Down

0 comments on commit 615d824

Please sign in to comment.