Pelles C forum

Pelles C => Bug reports => Topic started by: jstaple on May 09, 2005, 11:11:40 PM

Title: Find and replace bug
Post by: jstaple on May 09, 2005, 11:11:40 PM
First of all I want to say Pelles C rocks
Its a breath of fresh air to use a pure C compiler

I've been messing around with it a home for some time. And wanted to use it in anger at work. So I converted a small VB program to C (That worked fine). However on journey I found a bug...

I wanted to replace all the single quote VB comments with stars e.g

'''''''''''''''''''''''''' -> *****************
So I selected Edit->Replace in the ide menu and entered ' in the find what box and entered * in the replace with box and the results were...

'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*'*

Once again Pelles C rocks
Title: Find and replace bug
Post by: Pelle on May 09, 2005, 11:34:50 PM
Thank you for your kind words and the bug report. I will look at it/fix it.

Pelle
Title: another replace bug i think
Post by: Ateneo on May 12, 2005, 06:46:16 AM
i dont know if its a bug, but suppouse whe have all "HELLO" sitrings that we want to replace it by "HOLA" (spanish) :D , i make a selection of "HELLO" and then go to replace (that would be nice to have a shortcut to it, or have a button in the "search" dialog). Well the string is well copied to the "source", and then we write "HOLA" in "Dest", when we start to Replace all the strings, the first, the selected "HELLO" is not replaced, instead the following one. So the "replace" engine must end with the last "replaced" string, go to the beggining and replace the first "HELLO". It might be seen like this is unnecesary cos we had all "HELLO" and we replace all by "HOLA", but there are some cases where its is.

Again, thanks god (or you who make it) for Pelles C (and POIDE of course :))
Title: Re: another replace bug i think
Post by: Pelle on May 12, 2005, 09:32:34 PM
Quote from: "Ateneo"
i dont know if its a bug, but suppouse whe have all "HELLO" sitrings that we want to replace it by "HOLA" (spanish) :D , i make a selection of "HELLO" and then go to replace (that would be nice to have a shortcut to it, or have a button in the "search" dialog). Well the string is well copied to the "source", and then we write "HOLA" in "Dest", when we start to Replace all the strings, the first, the selected "HELLO" is not replaced, instead the following one. So the "replace" engine must end with the last "replaced" string, go to the beggining and replace the first "HELLO". It might be seen like this is unnecesary cos we had all "HELLO" and we replace all by "HOLA", but there are some cases where its is.

I'm not sure if it's a bug either - I will look at it when I have some time.

Using Ctrl+F for Find is pretty standard, but the key for Replace seems to differ more between programs. Use Tools -> Customize -> Keyboard if you want to change the accelerator keys...

Pelle
Title: Find and replace bug
Post by: l1ng0 on February 22, 2006, 06:26:33 AM
I have customized the shortcut, only to find the bug that I've reported here:

http://smorgasbordet.com/phpBB2/viewtopic.php?p=5077#5077

Thanks,
 - Luke