Skip to content

Commit 21bca6c

Browse files
committed
fix: ValueRef::as_bstr() now uses the correct lifetime.
This makes it more usable as the value lives longer than the ref itself.
1 parent 0762846 commit 21bca6c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

gix-attributes/src/state.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ impl<'a> ValueRef<'a> {
2323
}
2424

2525
/// Access and conversions
26-
impl ValueRef<'_> {
26+
impl<'a> ValueRef<'a> {
2727
/// Access this value as byte string.
28-
pub fn as_bstr(&self) -> &BStr {
28+
pub fn as_bstr(&self) -> &'a BStr {
2929
self.0.as_bytes().as_bstr()
3030
}
3131

0 commit comments

Comments
 (0)