|
From: | Manuel Collado |
Subject: | Re: [bug-gawk] inside awk script check that -M/--bignum given on command line? |
Date: | Mon, 8 Jan 2018 17:27:28 +0100 |
User-agent: | Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.5.0 |
El 08/01/2018 a las 16:25, Andrew J. Schorr escribió:
On Mon, Jan 08, 2018 at 07:39:17AM -0700, address@hidden wrote:W.R.T. End rule order, yes, you do have to make sure that assert.awk (or a theoretical abort.awk) is the first part of the whole awk program.... I wonder whether it could be implemented in an extension library. I suppose the function could simply call 'exit', and that would eliminate the ordering fragility of using an include library. ... The problem with using a library is that we lose the ability to retain the default exit status if none is provided to the function...
What about an abort() extension that just invokes a 'fatal' error? It can be a partial solution. No custom exit status, but it can be part of the error message.
Regards. -- Manuel Collado - http://lml.ls.fi.upm.es/~mcollado
[Prev in Thread] | Current Thread | [Next in Thread] |