Update range.

This commit is contained in:
Christoffer Lerno
2023-07-19 21:56:52 +02:00
parent 7fbedae604
commit c4f8d5f25e
2 changed files with 8 additions and 8 deletions

View File

@@ -16,7 +16,7 @@ fn usz Range.len(&self) @operator(len)
return (usz)(self.end - self.start + (Type)1);
}
fn bool Range.has(&self, Type value) @inline
fn bool Range.contains(&self, Type value) @inline
{
return value >= self.start && value <= self.end;
}
@@ -51,7 +51,7 @@ fn usz ExclusiveRange.len(&self) @operator(len)
return (usz)(self.end - self.start);
}
fn bool ExclusiveRange.has(&self, Type value) @inline
fn bool ExclusiveRange.contains(&self, Type value) @inline
{
return value >= self.start && value < self.end;
}