From: Mike C. <MF...@uk...> - 2009-02-27 17:13:45
|
> I'm starting to come around to the position that the default digits > setting should be 9 (not completely convinced yet, but close). > However, I think that if this is done, then there are some additional > things that need to be added. One is a ::options directive to allow > these things to be tailored on a source file basis. So here's a > straw-man proposal for a directive: > > ::OPTIONS DIGITS digits FORM form FUZZ fuzz TRACE trace STRICTNOVALUE > > All options are optional, and can be specified in any order or > multiple times. Last one wins if there are multiples. The OPTIONS > directive may appear anywhere after the main program section of the > source file, and can be specified multiple times as well (last one > wins applies here too, if an option appears on multiple directives). > All options apply to all Rexx code contained within the source file. > So for, example, including > > ::options digits 18 > > would mean that an initial digits setting of 18 will be used for all > Rexx code created this source file. This includes the main program, > all routines declared using ::ROUTINE, and all methods. Sounds good. (Remind me why it couldn't appear before the main program?) > All option values must be either a symbol taken as a constant or a > literal string. No expression evaluation takes place with directives, > which are static source descriptors. > > The options are fairly self-explanatory, but I think there is a need > for some keyword for DIGITS that means "use the same as the internal > built-in setting". Looking for a name suggestion on that one. How about: 9 ? :-) > The > STRICTNOVALUE is for people routinely enable NOVALUE traps in all > code. This will raise a SYNTAX error in any situation where a NOVALUE > condition would be raised. I'm waffling on the keyword here > too...perhaps this should be NOVALUE keyword with an option such as > CONDITION/SYNTAX or RELAXED/STRICT. In the theory that you want to be > able to explictly specify all forms of an option, probably the last > would be better. It could be: SIGNALON condition and maybe allow: CALLON condition too. (Perhaps only allow NOVALUE for the condition at first.) > Given that I'm going to the trouble of implementing this, I'd like to > make it apply to more than just the digits setting, hence the > additional options. Makes sense. Mike Unless stated otherwise above: IBM United Kingdom Limited - Registered in England and Wales with number 741598. Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU |