[Developers] [Patches] ability to comment variables in e.g. Cactus out?D_vars

Ian Hinder ian.hinder at aei.mpg.de
Fri Jun 25 01:58:43 CDT 2010

On 25 Jun 2010, at 00:44, Frank Loeffler wrote:

> Hi,
> On Fri, Jun 25, 2010 at 12:31:09AM -0400, Erik Schnetter wrote:
>> This implementation seems to require that the hash comment  
>> character is immediately in front of the variable name, without  
>> intervening white space.
> That is right. I didn't want to break variable names which start  
> with an
> '#'. That however would be rather exotic and I am not sure if even  
> Cactus
> would allow that in the first place.
>> It still doesn't allow comments.
> Do we really need comments _inside_ a variable value?
> The actual implementation of anything inside that code would be so  
> much
> easier if one could use regular expressions to parse the code.
> Implementing matching (* *) with the current C code will for sure  
> create
> at least some headache.

How about simply adding a flesh parameter  
"ignore_unknown_output_variables" which would cause variables selected  
for output from inactive (or non-compiled-in thorns) to be ignored  
(possible emitting a warning)?  I would even go so far as to suggest  
that this should be the default.

Reasons for aborting on unknown variables:

* The user might have mistyped the variable name
* The user might want output for it and had forgotten to activate the  

I think that if you emit a warning this should be sufficient to  
address the above problems.

Or maybe you could insist that the variables are contained in compiled  
thorns, but not in active ones.  This would allow you to catch the  
case of a typo in the variable name.

Ian Hinder
ian.hinder at aei.mpg.de

More information about the Developers mailing list