all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: florian <lorian@fsavigny.de>
To: help-gnu-emacs@gnu.org
Subject: Is X'ABCD' notation of general interest? (was: Converting strings of hexadecimal numbers to the respective bytes)
Date: Thu, 9 Apr 2009 03:05:03 -0700 (PDT)	[thread overview]
Message-ID: <45202d31-fd33-4b35-9bb7-fe4af6eb4012@c9g2000yqm.googlegroups.com> (raw)
In-Reply-To: mailman.4740.1239058484.31690.help-gnu-emacs@gnu.org


Juanma,

>   (string-to-number string &optional base)

many thanks. I swear I did RTFM, or rather rummage it, but I obviously
missed that important bit.

Your hint was just what I lacked, and I used it to program two small
functions for converting strings in X'ABCD' notation into their binary
form and vice versa, along with two functions to do the same with file
contents (i.e. file contents to X'ABCD' and vice versa).

The X'ABCD' notation represents arbitrary bytes as their two-digit
hexadecimal representation, which produces strings that have double
the size and can be passed over the command line (SQLite uses this).
Does anybody think that functions to handle that (I have round-trip
tested them) would be of general interest, so that posting them on
gnu.emacs.sources would make sense? (Just don't want to clutter public
space needlessly.)

Many thanks again, and best regards,

Florian


  parent reply	other threads:[~2009-04-09 10:05 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-06 22:22 Converting strings of hexadecimal numbers to the respective bytes florian
2009-04-06 22:54 ` Juanma Barranquero
     [not found] ` <mailman.4740.1239058484.31690.help-gnu-emacs@gnu.org>
2009-04-09 10:05   ` florian [this message]
2009-04-09 12:24     ` Is X'ABCD' notation of general interest? (was: Converting strings of hexadecimal numbers to the respective bytes) Juanma Barranquero
2009-04-12 11:45     ` Is X'ABCD' notation of general interest? Thien-Thi Nguyen
2009-04-12 21:25       ` Nikolaj Schumacher
2009-04-13 14:12         ` Thien-Thi Nguyen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=45202d31-fd33-4b35-9bb7-fe4af6eb4012@c9g2000yqm.googlegroups.com \
    --to=lorian@fsavigny.de \
    --cc=help-gnu-emacs@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.