diff --git a/src/s2/util/coding/coder.h b/src/s2/util/coding/coder.h index f6556774..df633a2c 100644 --- a/src/s2/util/coding/coder.h +++ b/src/s2/util/coding/coder.h @@ -134,7 +134,7 @@ class Encoder { // REQUIRES: length() >= N // Removes the last N bytes out of the encoded buffer - void RemoveLast(size_t N) { writer().skip(-N); } + void RemoveLast(size_t N) { writer().skip(-static_cast(N)); } // REQUIRES: length() >= N // Removes the last length()-N bytes to make the encoded buffer have length N