Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!newsreader4.netcologne.de!news.netcologne.de!bcyclone02.am1.xlned.com!bcyclone02.am1.xlned.com!newsfeed.xs4all.nl!newsfeed2a.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.004 X-Spam-Evidence: '*H*': 0.99; '*S*': 0.00; 'subject:Python': 0.06; 'dynamically': 0.07; 'statically': 0.07; 'typed': 0.09; 'cc:addr :python-list': 0.11; "wouldn't": 0.14; 'evaluates': 0.16; 'once.': 0.16; 'statement.': 0.16; 'to:addr:pearwood.info': 0.16; 'to:addr:steve+comp.lang.python': 0.16; "to:name:steven d'aprano": 0.16; 'wrote:': 0.18; 'value.': 0.19; 'feb': 0.22; 'cc:addr:python.org': 0.22; 'copied': 0.24; 'pointer': 0.24; 'cc:2**0': 0.24; 'header:In-Reply-To:1': 0.27; 'function': 0.29; 'am,': 0.29; 'message-id:@mail.gmail.com': 0.30; "d'aprano": 0.31; 'pascal': 0.31; 'steven': 0.31; 'types.': 0.31; 'probably': 0.32; 'compatible': 0.32; 'languages': 0.32; 'maybe': 0.34; 'something': 0.35; 'no,': 0.35; 'but': 0.35; 'received:google.com': 0.35; 'really': 0.36; 'similar': 0.36; 'e.g.': 0.38; 'expect': 0.39; 'different': 0.65; 'family': 0.73; 'subject:! ': 0.74; '2015': 0.84 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=xqi/cAAT7uH3h6U+9cwYeHFuFIO23udmcc9Evs0IQmQ=; b=HE5P83cIcm6XUW4PoX4WzwGw/s3FvFya5t+XrWctmUV0N2raq+91yEs30hibjPR7gD S4adXJ+fdQ7K58V9747xGiF3XM7991gLHldO4KflUGvs/3EYmhTo5BaLiC01Xi4tQebW PNE0KKYbQxIClEa9/DnCgJvDnjdJKtCHTZA2Ibe8TPkv/IcU8HdbB16ugwIemNfrlKz/ sUff+tmn4s4mMtwPK6ocw+Hbh+s7N25KbNzopHOx2dw13jyC7mPRUqAjWg9jwORkLQRP HE8n/LUa8D+JlqLyWNnTdlwrEfkG2TikpqTGkmX7RaKPP9kufaX9r4xxn+tSJYbU84Zj b++Q== X-Received: by 10.224.19.193 with SMTP id c1mr31947786qab.73.1422809722642; Sun, 01 Feb 2015 08:55:22 -0800 (PST) MIME-Version: 1.0 In-Reply-To: <54ce5593$0$12989$c3e8da3$5496439d@news.astraweb.com> References: <54c07d04$0$13012$c3e8da3$5496439d@news.astraweb.com> <6eb91c4b-92ff-44a8-b5a9-6ef04c71f4cb@googlegroups.com> <35a40ec6-3763-448b-9ea4-4a233a04979b@googlegroups.com> <54c1ccc8$0$13005$c3e8da3$5496439d@news.astraweb.com> <54c6d7c2$0$12992$c3e8da3$5496439d@news.astraweb.com> <54c83ab4$0$12982$c3e8da3$5496439d@news.astraweb.com> <54ca583e$0$13005$c3e8da3$5496439d@news.astraweb.com> <54ccc2fc$0$13009$c3e8da3$5496439d@news.astraweb.com> <8761bm40ud.fsf@jester.gateway.sonic.net> <54ce5593$0$12989$c3e8da3$5496439d@news.astraweb.com> From: Devin Jeanpierre Date: Sun, 1 Feb 2015 08:54:42 -0800 Subject: Re: Python is DOOMED! Again! To: "Steven D'Aprano" Content-Type: text/plain; charset=UTF-8 Cc: "comp.lang.python" X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 24 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1422809731 news.xs4all.nl 2910 [2001:888:2000:d::a6]:43627 X-Complaints-To: abuse@xs4all.nl X-Received-Bytes: 5379 X-Received-Body-CRC: 785460801 Xref: csiph.com comp.lang.python:85008 On Sun, Feb 1, 2015 at 8:34 AM, Steven D'Aprano wrote: > Devin Jeanpierre wrote: > >> It's really only dynamically typed languages that have a single null >> value of a single type. Maybe I misunderstand the original statement. > > Pascal is statically typed and has a single null pointer compatible with all > pointer types. C has a single nil pointer compatible with all pointer > types. I expect that the Modula and Oberon family of languages copied > Pascal, which probably copied Algol. No, C has a NULL macro which evaluates to something which coerces to any pointer type and will be the null value of that type. But there's one null value per type. The C standard makes no guarantees that they are compatible in any way, e.g. they can be of different sizes. On some systems, the null function pointer will have a size of N, where the null int pointer will have a size of M, where N != M -- so these are clearly not the same null value. I don't know Pascal, but I wouldn't be surprised if something similar held, as nonuniform pointer sizes were a thing once. -- Devin