From 0a68026c86b27ad76cad2854e84bb61a020a1521 Mon Sep 17 00:00:00 2001 From: sof <unknown> Date: Mon, 9 Feb 1998 13:04:03 +0000 Subject: [PATCH] [project @ 1998-02-09 13:04:03 by sof] Reworded note on the sign extension of shift ops. --- ghc/docs/libraries/libs.sgml | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/ghc/docs/libraries/libs.sgml b/ghc/docs/libraries/libs.sgml index 7c41ea64bd2d..8869e9f02a82 100644 --- a/ghc/docs/libraries/libs.sgml +++ b/ghc/docs/libraries/libs.sgml @@ -328,12 +328,10 @@ Notes: the number of bits in the type (or <tt/Nothing/ for unbounded types); and <tt/isSigned/ returns whether the type is signed or not. <item> - <tt/shift/ performs sign extension. - That is, right shifts fill the top bits with 1 if the number is negative + <tt/shift/ performs sign extension on signed number types. + That is, right shifts fill the top bits with 1 if the number is negative and with 0 otherwise. - (Since unsigned types are always positive, the top bit is always filled with - 0.) -<item> +<item> Bits are numbered from 0 with bit 0 being the least significant bit. <item> <tt/shift x i/ and <tt/rotate x i/ shift to the left if <tt/i/ is -- GitLab