forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Undoing Messes Up Code

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Plato
View previous topic :: View next topic  
Author Message
viroxa



Joined: 28 Jul 2017
Posts: 78

PostPosted: Thu Aug 03, 2017 11:07 pm    Post subject: Undoing Messes Up Code Reply with quote

Good evening,

Is anyone else having the problem that code is deleted, scrambled, messed up while undoing in v. 4.75?
Back to top
View user's profile Send private message
mecej4



Joined: 31 Oct 2006
Posts: 1884

PostPosted: Thu Aug 03, 2017 11:32 pm    Post subject: Reply with quote

I just tried to reproduce your problem using Plato 4.75 on a randomly selected Fortran source file. Nothing happened when I changed a few characters scattered over different lines and did 'undo' the requisite number of times. Each time, the 'undo' affected the only characters that had been changed.

Can you make the problem happen in a reproducible way? With any source file? If not, provide specific information.
Back to top
View user's profile Send private message
viroxa



Joined: 28 Jul 2017
Posts: 78

PostPosted: Fri Aug 04, 2017 8:37 pm    Post subject: Reply with quote

I could not reproduce the problem at will. The next time it happens, I'll try to reproduce it in the file where it occures or at least I'll be able to analyze the circumstances.
Back to top
View user's profile Send private message
viroxa



Joined: 28 Jul 2017
Posts: 78

PostPosted: Wed Aug 09, 2017 1:28 pm    Post subject: Reply with quote

I'm afraid it's not reproducable on purpose. Sometimes it happens, sometimes it doesn't, without detectable pattern.

Sometimes even asian symbols appear at the current cursor position.
Back to top
View user's profile Send private message
viroxa



Joined: 28 Jul 2017
Posts: 78

PostPosted: Fri Sep 22, 2017 10:39 am    Post subject: Reply with quote

I've finally managed to reproduce the error (Plato 4.75):

1. Create a new .f95-file
2. Skip 2 lines
3. In line 3 add ALLOCATE(test(2)) and save
4. Cut out test(2) using Ctrl+X
5. In line 1 add ! followed by a tab and some letters (doesn't matter which or how many)
6. Delete the comment
7. In line 1 add ALLOCATE(
8. Paste test(2) using Ctrl+V and close the bracket
9. Start undoing using Ctrl+Z

Around the 6th undo you should end up with ALLOCATE()test(2) in line 2 or ALLTE in line 1.

[/code]
Back to top
View user's profile Send private message
mecej4



Joined: 31 Oct 2006
Posts: 1884

PostPosted: Fri Sep 22, 2017 1:13 pm    Post subject: Reply with quote

Yes, I can reproduce the error using the steps that you provided.

However, the misplaced text seems to be only in the version that is in the screen display.

If, after you see the malformed line, you save and reopen the file, the line in question can be seen to be unaffected by the bug.
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7912
Location: Salford, UK

PostPosted: Fri Sep 22, 2017 1:17 pm    Post subject: Reply with quote

viroxa

I have tried this sequence but it works OK for me.

"Skip 2 lines" is not precise so I may be doing something different.
Similarly "Delete the comment" is not precise.

The only other thing is that I am using the latest Plato but I don't think it will make any difference.

You can download the latest Plato using the link here...

http://forums.silverfrost.com/viewtopic.php?t=3602
Back to top
View user's profile Send private message AIM Address
viroxa



Joined: 28 Jul 2017
Posts: 78

PostPosted: Fri Sep 22, 2017 2:45 pm    Post subject: Reply with quote

mecej4, thanks for pointing that out. So far I haven't dared to save after messing everything up.

Paul:
"Skip 2 Lines": Leave lines 1 and 2 blank

"Delete the comment": Either select the whole comment and hit the DEL-key or delete it by using backspace. It's only important, that you remove the comment from line 1 before typing in ALLOCATE( in the same line.

Thanks for providing the link. I'll give it a try.
Back to top
View user's profile Send private message
viroxa



Joined: 28 Jul 2017
Posts: 78

PostPosted: Fri Sep 22, 2017 2:47 pm    Post subject: Reply with quote

Paul, the error still occurs, I'm afraid.

mecej4, you're right, after closing and reopening, everything's where it's supposed to be.
Back to top
View user's profile Send private message
mecej4



Joined: 31 Oct 2006
Posts: 1884

PostPosted: Fri Sep 22, 2017 3:27 pm    Post subject: Re: Reply with quote

PaulLaidler wrote:

"Skip 2 lines" is not precise so I may be doing something different.
Similarly "Delete the comment" is not precise.

I had the same reaction as Paul regarding the directions that Viroxa gave.

I had used Plato 4.75 when I was able to reproduce the problem. Just now, I tried Plato 4.81, and it does not display the problem.

Viroxa, you could just replace the version of the Plato editor that you have with the newer version that Paul gave you a link for.
Back to top
View user's profile Send private message
viroxa



Joined: 28 Jul 2017
Posts: 78

PostPosted: Fri Sep 22, 2017 5:51 pm    Post subject: Reply with quote

I already tried it with the new version, and the problem still occurs. But since it's only a display problem, I can live with it.
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7912
Location: Salford, UK

PostPosted: Mon Sep 25, 2017 12:26 pm    Post subject: Reply with quote

I can now reproduce the bug and I will make a note that it needs fixing.
Back to top
View user's profile Send private message AIM Address
viroxa



Joined: 28 Jul 2017
Posts: 78

PostPosted: Mon Sep 25, 2017 2:11 pm    Post subject: Reply with quote

Thanks!
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Plato All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group