From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: "Drew Adams" Newsgroups: gmane.emacs.help Subject: RE: ucs-insert no longer working Date: Sun, 14 Apr 2013 15:05:59 -0700 Message-ID: <4C3F325A73434A61997416EDFBEA6A8B@us.oracle.com> References: <87y5ckj0rl.fsf@gmx.ch> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1365977192 23724 80.91.229.3 (14 Apr 2013 22:06:32 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sun, 14 Apr 2013 22:06:32 +0000 (UTC) To: "'Sven Bretfeld'" , Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Apr 15 00:06:36 2013 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1URV4F-0006x0-Tj for geh-help-gnu-emacs@m.gmane.org; Mon, 15 Apr 2013 00:06:36 +0200 Original-Received: from localhost ([::1]:51921 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1URV4F-00019U-E2 for geh-help-gnu-emacs@m.gmane.org; Sun, 14 Apr 2013 18:06:35 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:47206) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1URV42-000190-K0 for help-gnu-emacs@gnu.org; Sun, 14 Apr 2013 18:06:24 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1URV41-00008P-JE for help-gnu-emacs@gnu.org; Sun, 14 Apr 2013 18:06:22 -0400 Original-Received: from aserp1040.oracle.com ([141.146.126.69]:38946) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1URV41-00008A-CS for help-gnu-emacs@gnu.org; Sun, 14 Apr 2013 18:06:21 -0400 Original-Received: from ucsinet22.oracle.com (ucsinet22.oracle.com [156.151.31.94]) by aserp1040.oracle.com (Sentrion-MTA-4.3.1/Sentrion-MTA-4.3.1) with ESMTP id r3EM6F5D011487 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sun, 14 Apr 2013 22:06:16 GMT Original-Received: from aserz7022.oracle.com (aserz7022.oracle.com [141.146.126.231]) by ucsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r3EM6EQw003551 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL); Sun, 14 Apr 2013 22:06:15 GMT Original-Received: from abhmt115.oracle.com (abhmt115.oracle.com [141.146.116.67]) by aserz7022.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r3EM6EaT003355; Sun, 14 Apr 2013 22:06:14 GMT Original-Received: from dradamslap1 (/71.202.147.44) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Sun, 14 Apr 2013 15:06:13 -0700 X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <87y5ckj0rl.fsf@gmx.ch> Thread-Index: Ac45UZoMQUIeeT42QeiTOukFcIpIHQACdD3Q X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: ucsinet22.oracle.com [156.151.31.94] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 141.146.126.69 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:90160 Archived-At: > (ucs-insert "0101") > > (wrong-type-argument characterp "0101") > > Calling ucs-insert manually with M-x works however. > What strange bug is that? It's not a bug. When you call the command interactively you are prompted for input and the command interprets that input. In this case it interprets your input of 0101 as a hex code for a character. But after that interactive dialong is finished, what is passed to the command body is the character. And a character in Emacs Lisp is an integer (only certain integers are chars, however). The command requires a character as its argument. "0101" is not a character. It is not even a non-character integer. It is a string. Try (ucs-insert ?\x0101) and you will see the difference. Consult the Elisp manual, node `Strings and Characters', and its subnodes.