summaryrefslogtreecommitdiff
path: root/src/syntax/ast.rs
diff options
context:
space:
mode:
authorLaurenz <laurmaedje@gmail.com>2022-12-02 15:47:25 +0100
committerLaurenz <laurmaedje@gmail.com>2022-12-02 15:47:25 +0100
commit56923ee472f1eaa67d3543e19372823139205885 (patch)
treeaccd9e05fb5875457967c5b456626767ff3e9c9e /src/syntax/ast.rs
parent9bc90c371fb41a2d6dc08eb4673e5be15f829514 (diff)
Multi-part numbering patterns
Diffstat (limited to 'src/syntax/ast.rs')
-rw-r--r--src/syntax/ast.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/syntax/ast.rs b/src/syntax/ast.rs
index 81ddd596..3c60acbb 100644
--- a/src/syntax/ast.rs
+++ b/src/syntax/ast.rs
@@ -365,7 +365,7 @@ node! {
impl EnumItem {
/// The explicit numbering, if any: `23.`.
- pub fn number(&self) -> Option<usize> {
+ pub fn number(&self) -> Option<NonZeroUsize> {
self.0.children().find_map(|node| match node.kind() {
SyntaxKind::EnumNumbering(num) => Some(*num),
_ => None,