[Mpi-22] Ticket #46: Add const Keyword to the C bindings-implementation

Pavan Balaji balaji at [hidden]
Thu Mar 19 20:20:42 CDT 2009



Hi Jeff,

> - testing that const is in the right places in the interface is 
> *exactly* the right kinds of tests to write.

Maybe I'm missing something here, but can you give some examples of 
tests that would fail with this change that a new and strict compiler 
will not be able to catch? Obviously I'm referring to cases which would 
work correctly if this ticket wasn't accepted, but will not work if it were.

Unless there are such examples, all this ticket requires is letting the 
compiler find the problems for you. In fact, some tickets in 2.1 
required more QA, as a compiler was useless in catching any real 
problems with them and new tests had to be written (e.g., the change 
with respect to 0-dim cartesian topologies, or any other trivial change).

Now, to keep the compiler quiet, whether the implementation directly 
discards the const at the top-level or carries it on to the lowest 
possible level (e.g., network interface) is a separate discussion and 
IMO really a quality of implementation issue. And, obviously, pushing 
this to 3.0 would not ensure that implementations will make an effort to 
do better.

So, what's the motivation to move this to 3.0?

Thanks,

  -- Pavan


-- 
Pavan Balaji
http://www.mcs.anl.gov/~balaji




More information about the Mpi-22 mailing list