[ET Trac] [Einstein Toolkit] #798: allow calculations in parameter assignments in parameter files

Einstein Toolkit trac-noreply at einsteintoolkit.org
Wed Apr 11 13:07:06 CDT 2012


#798: allow calculations in parameter assignments in parameter files
--------------------------+-------------------------------------------------
  Reporter:  rhaas        |       Owner:        
      Type:  enhancement  |      Status:  review
  Priority:  optional     |   Milestone:        
 Component:  Cactus       |     Version:        
Resolution:               |    Keywords:        
--------------------------+-------------------------------------------------

Comment (by rhaas):

 I added to "=" moniker because right now a number with a "=" would be
 invalid and it means that I can guarantee that the old parameter files are
 not affected (saves on flame emails). It is also a bit faster since each
 "=" trigger the constructions of a parser tree, recursive function calls
 etc.

 Attached please find an updated patch no longer requiring an extra "=", it
 first tries feeding its input to strol/atoi/SetBoolean and if that fails
 trys
 and expression parser.

 Python support would be nice, yes. Something that's easier to add support
 for is Tcl (at least I have added Tcl to some code in the past but never
 python).

 I can add a "system()" function easily that would use the result of a
 system() call :-P.

 Ian: A third option is to use simfactory's @(...)@ syntax.

 Do we still want the patch (it adds a third option for parameter
 dependencies).

 The parser itself would still be nice for grid functions.

-- 
Ticket URL: <https://trac.einsteintoolkit.org/ticket/798#comment:4>
Einstein Toolkit <http://einsteintoolkit.org>
The Einstein Toolkit


More information about the Trac mailing list