Skip to content

Commit d696aa6

Browse files
Ink Open Sourcecopybara-github
authored andcommitted
Add absl_nonnull annotation to CopyOnWrite::operator->
The lack of annotation is causing warnings in some build environments. PiperOrigin-RevId: 875728149
1 parent 40bfce5 commit d696aa6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ink/types/internal/copy_on_write.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ class CopyOnWrite {
101101

102102
// Returns a read-only pointer to the managed object. Behavior is undefined
103103
// if `HasValue()` returns `false`; CHECK-fails in debug.
104-
const T* operator->() const {
104+
const T* absl_nonnull operator->() const {
105105
ABSL_DCHECK(HasValue());
106106
return value_.get();
107107
}

0 commit comments

Comments
 (0)