From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andreas Schwab Newsgroups: gmane.emacs.devel Subject: Re: proposal to make null string handling more emacs-y Date: Sat, 28 Apr 2012 08:58:03 +0200 Message-ID: References: <83d36wfcf1.fsf@gnu.org> <834ns7g9r8.fsf@gnu.org> <83zk9xheam.fsf@gnu.org> <93BCB9FDF9D2443988F559AD4BEC4DBD@us.oracle.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1335596308 9690 80.91.229.3 (28 Apr 2012 06:58:28 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 28 Apr 2012 06:58:28 +0000 (UTC) Cc: Eli Zaretskii , monnier@iro.umontreal.ca, Drew Adams , emacs-devel@gnu.org To: Steve Yegge Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Apr 28 08:58:27 2012 Return-path: Envelope-to: ged-emacs-devel@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 1SO1bu-0002DZ-CT for ged-emacs-devel@m.gmane.org; Sat, 28 Apr 2012 08:58:26 +0200 Original-Received: from localhost ([::1]:54244 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SO1bt-0004I8-Ok for ged-emacs-devel@m.gmane.org; Sat, 28 Apr 2012 02:58:25 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:36550) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SO1br-0004I3-78 for emacs-devel@gnu.org; Sat, 28 Apr 2012 02:58:24 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SO1bp-0001zS-Hk for emacs-devel@gnu.org; Sat, 28 Apr 2012 02:58:22 -0400 Original-Received: from mail-out.m-online.net ([212.18.0.10]:38286) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SO1bm-0001yz-UQ; Sat, 28 Apr 2012 02:58:19 -0400 Original-Received: from frontend1.mail.m-online.net (frontend1.mail.intern.m-online.net [192.168.8.180]) by mail-out.m-online.net (Postfix) with ESMTP id 3VfjWx6VGbz3hhbx; Sat, 28 Apr 2012 08:58:05 +0200 (CEST) Original-Received: from linux.local (ppp-88-217-107-246.dynamic.mnet-online.de [88.217.107.246]) by mail.mnet-online.de (Postfix) with ESMTPA id 3VfjWy1mwzz4KK3C; Sat, 28 Apr 2012 08:58:06 +0200 (CEST) Original-Received: by linux.local (Postfix, from userid 501) id 5A98B1E5607; Sat, 28 Apr 2012 08:58:03 +0200 (CEST) X-Yow: ANN JILLIAN'S HAIR makes LONI ANDERSON'S HAIR look like RICARDO MONTALBAN'S HAIR! In-Reply-To: (Steve Yegge's message of "Fri, 27 Apr 2012 21:43:12 -0700") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.96 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Received-From: 212.18.0.10 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:150111 Archived-At: Steve Yegge writes: > The most recent occurrence is relatively fresh: I was observing some > annoying > behavior in a Google elisp library -- one that had been doing some path > manipulation > and choking on nil because, for whatever reason, `temporary-file-directory' > had > been bound to nil. So I fixed up the Google function to handle nil the > same way > it handles the empty string. And I glanced around and noticed that the same > hack had been applied all over the place, sometimes smoothed over with > macros > or what have you. It was a lot of smoothing over what appears to be a core > wrinkle. I see many places that check if temporary-file-directory is bound at all, but none that special cases a value of nil. This is just to support Emacs before 20.3 where the variable didn't exist yet. Andreas. -- Andreas Schwab, schwab@linux-m68k.org GPG Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5 "And now for something completely different."