Skip to content

Commit ab70eb3

Browse files
authored
Merge pull request #2 from Rigidity/fix-mistake
Fix mistake
2 parents 376cffb + c4acd8d commit ab70eb3

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

docs/types/type-checking.md

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -112,10 +112,9 @@ To achieve this, you can write your own recursive function to check instead:
112112

113113
```rue
114114
fun is_int_list(value: Any) -> Bool {
115-
match value {
116-
(Int, Any) => is_int_list(value.rest),
117-
nil => true,
118-
_ => false,
115+
if value is Bytes {
116+
return value == nil;
119117
}
118+
value.first is Int && is_int_list(value.rest)
120119
}
121120
```

0 commit comments

Comments
 (0)