]> git.eshelyaron.com Git - emacs.git/commitdiff
Pacify Oracle Studio re Time_to_position
authorPaul Eggert <eggert@cs.ucla.edu>
Sat, 25 Jun 2022 16:41:07 +0000 (11:41 -0500)
committerPaul Eggert <eggert@cs.ucla.edu>
Sat, 25 Jun 2022 20:28:08 +0000 (15:28 -0500)
* src/keyboard.c (Time_to_position): Use no-op position_to_Time to
pacify Oracle Studio 12.6’s “warning: initializer will be
sign-extended”.

src/keyboard.c

index ecc5a2169c9106ab0230692c099992dfea118df7..5b5972ceee4e6af4e974f9bd16efe74599ceb3a3 100644 (file)
@@ -3738,7 +3738,7 @@ Time_to_position (Time encoded_pos)
 {
   if (encoded_pos <= INPUT_EVENT_POS_MAX)
     return encoded_pos;
-  Time encoded_pos_min = INPUT_EVENT_POS_MIN;
+  Time encoded_pos_min = position_to_Time (INPUT_EVENT_POS_MIN);
   eassert (encoded_pos_min <= encoded_pos);
   ptrdiff_t notpos = -1 - encoded_pos;
   return -1 - notpos;