D const design rationale
Bill Baxter
dnewsgroup at billbaxter.com
Sat Jun 23 21:54:02 PDT 2007
Sean Kelly wrote:
> Derek Parnell wrote:
>> A second issue I have is that by forcing 'const' to be explicitly
>> coded in
>> function parameter lists, you are reducing the ability of the compiler to
>> help detect bugs.
>
> Isn't this necessary though? Say the function declaration is available
> to the compiler but the implementation is not. The compiler needs to
> know what kind of data can legally be passed as parameters.
I took that to mean he wanted to make const the default.
I too am disappointed that the only rebuttal from Walter on const by
default has been "some C++ guys I talked to thought it was weird".
--bb
More information about the Digitalmars-d
mailing list