On Mon, 1 Jun 2015 16:23:27 -0700 (PDT)
Brad Chamberlain <[email protected]> wrote:
...
> >>      config var m = 10,
> >>                 n = m;
> >> 
> >> would you prefer ./a.out --help to say:
> >>
> >>      m = 10
> >>      n = m
...
> >>      m = 10
> >>      n = 10
...
> that if you run:
> 
>       ./a.out --m=100
> 
> then n will still be 10?  (because it won't, it'll actually be 100).
> This is what made me ask about the first form.

For this exact reason I think showing n = 10, m = 10 is clearly
misleading and should be avoided. Why not simply output the default
for n as a string like "expression: m" or for your example below
"expression: computeProblemSize(Locales, m, pi)"?

...
>       config var n = computeProblemSize(Locales, m, pi);
> 
> then seeing the following in your help message:
> 
>       n = computeProblemSize(Locales, m, pi)

I actually think it's quite helpful. It shows that unless overridden n
will be calculated by (a hopefully helfully named) function of
Locales, m and pi.

/Peter K
 
> isn't actually very helpful.  So maybe you actually want both to
> avoid both of these pitfalls.  :(

------------------------------------------------------------------------------
_______________________________________________
Chapel-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/chapel-users

Reply via email to