dejagnu
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: PATCH: fix isbuild, ishost, istarget defaults


From: Jacob Bachmeyer
Subject: Re: PATCH: fix isbuild, ishost, istarget defaults
Date: Thu, 29 Nov 2018 16:02:25 -0600
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.8.1.22) Gecko/20090807 MultiZilla/1.8.3.4e SeaMonkey/1.1.17 Mnenhy/0.7.6.0

Ben Elliston wrote:
The documentation implies that you can call procs isbuild, ishost and
istarget with no argument to return these triplets. However, passing
"" is not the same as passing nothing in Tcl:

% proc foo {arg} { puts $arg }
% foo ""

% foo
wrong # args: should be "foo arg"

This patch fixes these procs so that they can be called without an
argument. This remains compatible with the existing behaviour.

OK to commit?

I have two comments, both about the documentation changes:

First, the documentation references to "NULL" or "NULL string" make no sense in Tcl and *should* be changed (as this patch starts to do) to "empty string". (In other words, are there more places to change? There is no "NULL" in Tcl.)

Second, instead of "If called with no arguments", the documentation should say "If called with no arguments or an empty string", since that is what the function actually examines.

-- Jacob




reply via email to

[Prev in Thread] Current Thread [Next in Thread]