On Wed, Feb 17, 2016 at 09:07:42AM -0700, Sandra Loosemore wrote: > On 02/17/2016 12:14 AM, Tom de Vries wrote: > > > >Here's the documentation entry for the gt spec function (I forgot to add > >it when introducing the function), using the new semantics. > > > >Copy-pasting from the resulting .info viewed in emacs for a > >human-readable version: > >... > > 'gt' > > The 'gt' (greater than) function takes one or more arguments. > > It returns either NULL or the empty string. If it has one > > argument, it returns NULL. If it has two arguments, it > > compares them: it returns the empty string if the first > > argument is greater than the second argument, otherwise it > > returns NULL. If it has more than two arguments, it behaves > > as if only the last two arguments were passed. It can be used > > f.i. as 'S' in a spec directive %{'S':'X'}: if 'S' is NULL, > > the empty string is substituted, and if 'S' is the empty > > string, 'X' is substituted. > > > > %:gt(%{fsome-option-value=*:%*} 1) > >... > > > >OK for stage4 trunk? > > I'm not an expert on spec strings.... but from a user perspective, what is > the difference between "NULL" and "the empty string"? The other spec > escapes are documented in terms of pattern substitutions at the point where > the escape appears in the spec string.
NULL vs. "" is the internal (C level representation) of %:fn() function returned false vs. true for the purpose of e.g. %{%:fn():...}. Jakub