Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2016-06

Refactoring functionality is broken

3 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Graeme Geldenhuys

Hi,

I'm using Lazarus 1.7 r52282 FPC 2.6.4 x86_64-linux-gtk2. None of the refactoring functionality seems to be working in my copy of Lazarus. Not sure if this was a known issue and already fixed, but I thought I would mention it here, in case this issue went unnoticed.

I tried "Make resourcestring" and "Extract procedure". Both got halfway with the refactoring - by that I mean the string constant got replaced with the resource string name, but the actual resource string variable never got defined. In the case of the Extract Procedure, a similar thing happened. The selected code got replaced with the new procedure name, but the actual procedure never got defined.

In both cases I received an error (see attached screenshot), and then the editor highlighting went totally out of whack. I had to close down Lazarus, restore my code from the code repository and then start Lazarus again. Needless to say, I didn't attempt any further refactoring.

I think the only refactoring that does work on my system is "Rename Identifier" - but that is probably because it is the simplest refactoring of the available options - equivalent to a Search & Replace.

Regards,
Graeme

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://fpgui.sourceforge.net/ My public PGP key: http://tinyurl.com/graeme-pgp -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot at 2016-06-02 15:49:06.png Type: image/png Size: 9278 bytes Desc: not available URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20160602/2a0aafc6/attachment-0001.png>

Reply by email

Martin Frb
to Graeme Geldenhuys
Graeme Geldenhuys wrote
Hi, I'm using Lazarus 1.7 r52282 FPC 2.6.4 x86_64-linux-gtk2. None of the

....

Show quoted text 5 lines
In both cases I received an error (see attached screenshot), and then the editor highlighting went totally out of whack. I had to close down Lazarus, restore my code from the code repository and then start Lazarus again. Needless to say, I didn't attempt any further refactoring.

Have you got any code to reproduce this?

You might be able to work around by switching off ifdef lowlight ing. (set all involved colors to none)

Reply by email

Graeme Geldenhuys
to Martin Frb
Martin Frb wrote
Have you got any code to reproduce this?

Unfortunately I am not allowed to share/publish any of the code I'm currently working on. But I will test the behaviour on open source code and let you know.

You might be able to work around by switching off ifdef lowlight ing.

Will do, and report back tomorrow.

Regards,
Graeme

fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://fpgui.sourceforge.net/ My public PGP key: http://tinyurl.com/graeme-pgp

Reply by email