all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#23111: 25.0.92; logxor leading zero missed
@ 2016-03-25  9:17 Andreas Röhler
  2016-03-25 16:00 ` Michael Heerdegen
  0 siblings, 1 reply; 3+ messages in thread
From: Andreas Röhler @ 2016-03-25  9:17 UTC (permalink / raw)
  To: 23111

(logxor 110 011) ==> 101 ; right
(logxor 110 101) ==> 11  ; leading zero is missed

;;

In GNU Emacs 25.0.92.1 (i686-pc-linux-gnu, GTK+ Version 2.24.25)
  of 2016-03-03
Windowing system distributor 'The X.Org Foundation', version 11.0.11604000
System Description:    Debian GNU/Linux 8.3 (jessie)

Configured features:
XPM JPEG TIFF GIF PNG RSVG SOUND GPM DBUS GSETTINGS NOTIFY ACL LIBXML2
FREETYPE M17N_FLT LIBOTF XFT ZLIB TOOLKIT_SCROLL_BARS GTK2 X11

Important settings:
   value of $LANG: de_DE.utf8
   value of $XMODIFIERS: @im=ibus
   locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
   tooltip-mode: t
   global-eldoc-mode: t
   electric-indent-mode: t
   mouse-wheel-mode: t
   tool-bar-mode: t
   menu-bar-mode: t
   file-name-shadow-mode: t
   global-font-lock-mode: t
   font-lock-mode: t
   blink-cursor-mode: t
   auto-composition-mode: t
   auto-encryption-mode: t
   auto-compression-mode: t
   line-number-mode: t
   transient-mark-mode: t

Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Mark set
Quit

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message dired format-spec rfc822 mml
mml-sec epg epg-config gnus-util mm-decode mm-bodies mm-encode
mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047
rfc2045 ietf-drums mm-util help-fns help-mode easymenu cl-loaddefs pcase
cl-lib mail-prsvr mail-utils time-date mule-util tooltip eldoc electric
uniquify ediff-hook vc-hooks lisp-float-type mwheel x-win
term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe
tabulated-list newcomment elisp-mode lisp-mode prog-mode register page
menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock
syntax facemenu font-core frame cl-generic cham georgian utf-8-lang
misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms
cp51932 hebrew greek romanian slovak czech european ethiopic indian
cyrillic chinese charscript case-table epa-hook jka-cmpr-hook help
simple abbrev minibuffer cl-preloaded nadvice loaddefs button faces
cus-face macroexp files text-properties overlay sha1 md5 base64 format
env code-pages mule custom widget hashtable-print-readable backquote
dbusbind inotify dynamic-setting system-font-setting font-render-setting
move-toolbar gtk x-toolkit x multi-tty make-network-process emacs)

Memory information:
((conses 8 159387 4604)
  (symbols 24 37793 0)
  (miscs 20 43 127)
  (strings 16 49999 5945)
  (string-bytes 1 716536)
  (vectors 8 12531)
  (vector-slots 4 449557 5660)
  (floats 8 167 310)
  (intervals 28 235 13)
  (buffers 520 11)
  (heap 1024 38620 797))







^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#23111: 25.0.92; logxor leading zero missed
  2016-03-25  9:17 bug#23111: 25.0.92; logxor leading zero missed Andreas Röhler
@ 2016-03-25 16:00 ` Michael Heerdegen
  2016-03-25 18:57   ` Andreas Röhler
  0 siblings, 1 reply; 3+ messages in thread
From: Michael Heerdegen @ 2016-03-25 16:00 UTC (permalink / raw)
  To: Andreas Röhler; +Cc: 23111

Andreas Röhler <andreas.roehler@easy-emacs.de> writes:

> (logxor 110 011) ==> 101 ; right
> (logxor 110 101) ==> 11  ; leading zero is missed

I think this is expected: logxor returns an integer, and "11" and "011"
are just different printed representations for the same number: 11.  The
lisp printer can't know that in this special case, it would make sense
to print 11 differently.  Even if it did, this wouldn't make any
difference for coding anyway.


Michael.





^ permalink raw reply	[flat|nested] 3+ messages in thread

* bug#23111: 25.0.92; logxor leading zero missed
  2016-03-25 16:00 ` Michael Heerdegen
@ 2016-03-25 18:57   ` Andreas Röhler
  0 siblings, 0 replies; 3+ messages in thread
From: Andreas Röhler @ 2016-03-25 18:57 UTC (permalink / raw)
  To: Michael Heerdegen; +Cc: 23111



On 25.03.2016 17:00, Michael Heerdegen wrote:
> Andreas Röhler <andreas.roehler@easy-emacs.de> writes:
>
>> (logxor 110 011) ==> 101 ; right
>> (logxor 110 101) ==> 11  ; leading zero is missed
> I think this is expected: logxor returns an integer, and "11" and "011"
> are just different printed representations for the same number: 11.  The
> lisp printer can't know that in this special case, it would make sense
> to print 11 differently.  Even if it did, this wouldn't make any
> difference for coding anyway.
>
>
> Michael.

close 23111

Okay, thanks. Nesting it works as expected. Seem no problem indeed.

(logxor (logxor 110 101)(logxor 110 001)) ==> 100






^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-03-25 18:57 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-25  9:17 bug#23111: 25.0.92; logxor leading zero missed Andreas Röhler
2016-03-25 16:00 ` Michael Heerdegen
2016-03-25 18:57   ` Andreas Röhler

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.