> Yes it is. But I do not think that most of people agree with your
> conclusion because it's not the source of formal errors but method
> of detecting real errors when declaration and implementation is different.
> If you do not like declarations at all then it's your choice but usually
> users like strong typing and similar features. They help to locate
> errors and typos at compile time. I.e. I still miss compile time support
> for method name verification so when I make typo like:
>   oPrn:AskProperites := .T.
> the error is generated at runtime only.

That's actually the reason I still keep out from 
using OO in Harbour (Clipper). Very easy to create 
RTE due to simple typo. And simple typos happen often.

> Anyhow it's programmer your choice what to chose and it's
> the reason why I enabled such verification only optionally
> for -w3 and higher level warning and even in such case leaving
> Class(y) compatible declaration method which does not force
> strict parameter validation.

Well, IMO it could be enabled all the time, because 
it's such a good tool to help creating good code.

I guess this would lead to hard debate, but Clipper 
(and thus Harbour) .prg code can be very sloppy and 
the same thing can be written in dozens of syntax 
variations. Maybe this is regarded a "strength" by 
some programmers, but I think it's one of the barriers 
to move Harbour closer to "modern" languages like 
f.e. C#, where it's much more difficult to write 
bad or dubiously looking code (= hard to read for 
anyone else but the writer).

Any steps to change this in Harbour can only be gradual 
while keeping way to stay fully compatible, but IMO 
it would be great if Harbour compiler could help even 
more to create cleaner, better code with less RTE 
traps and better readability. One tool is to provide 
_less_ options (synonyms) to express the same thing, 
plus features like strong typing. Anyway it's probably 
still too early to think about these things yet.

Brgds,
Viktor

_______________________________________________
Harbour mailing list (attachment size limit: 40KB)
[email protected]
http://lists.harbour-project.org/mailman/listinfo/harbour

Reply via email to