[Lazarus] Class completion in reverse - remove method implementation

Michael Van Canneyt michael at freepascal.org
Fri Oct 9 15:38:50 CEST 2009



On Fri, 9 Oct 2009, Hans-Peter Diettrich wrote:

> Graeme Geldenhuys schrieb:
>
>> Is there a function in the IDE to delete the implementation of a
>> method when the Interface signature is removed? Almost like class
>> completion, but in reverse?
>
> A very dangerous feature. When the tool cannot match properly declaration and 
> implementation header/signature, much code can be destroyed.
>
> I'd agree with a refactoring feature, to delete both interface and 
> implementation of a selected method. That feature could safely do nothing in 
> case of a mismatch.

Simply removing a method with empty implementation if the header is in the 
published section would also be nice. A misclick in the OI causes an empty
method to be generated. Deleting these automatically on compilation/save 
would be a nice thing. (as Delphi does, incidentally)

Michael.




More information about the Lazarus mailing list