Author Topic: Searching forward works, backwards won't find term  (Read 2469 times)

rajkej

  • Senior Community Member
  • Posts: 291
  • Hero Points: 13
Searching forward works, backwards won't find term
« on: October 28, 2016, 04:30:39 pm »
I haven't been able to build a file that reproduces this issue that I can send you. But there have been two times since I updated to 21.0.0.12 that I have encountered this issue. I saw this issue in 20.x version as well but somebody made a fix at that time by finding some internal buffering issue.

21.0.0.12 without patches, seen this once
21.0.0.12 with hot fix revision 4, seen this once

What happens is I search on some term in my .cpp file. I go forward through the file then backwards. Then at some point the backwards search stops working but I know the term is earlier in the file. So I go to the beginning of the file and search forwards and it finds the earliest matching term. If I close the file and reopen it then the problem goes away.

My search forward key bind is using find-next and backward is find-prev

Dan

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 2425
  • Hero Points: 136
Re: Searching forward works, backwards won't find term
« Reply #1 on: October 28, 2016, 04:32:04 pm »
Did you maybe have the search scope set to Current Procedure?

rajkej

  • Senior Community Member
  • Posts: 291
  • Hero Points: 13
Re: Searching forward works, backwards won't find term
« Reply #2 on: October 28, 2016, 04:34:29 pm »
No. I definitely found the term throughout the entire file going forwards even when broken. I found the term going backwards all except for the first occurrence of the term.

Last time this happened somebody at SE created some type of test case for how your internal buffers were managed and found an issue using that test case. I think that was within the past year.

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 5092
  • Hero Points: 421
Re: Searching forward works, backwards won't find term
« Reply #3 on: October 28, 2016, 10:12:06 pm »
Do you remember your search options?

Case sensitive? Regex? What you were searching for?

What OS are you running on. May help us determine file encoding.

Also, did you see this problem in 20.0.3? I think the fixes you mention were in this version.
« Last Edit: October 28, 2016, 11:04:34 pm by Clark »

rajkej

  • Senior Community Member
  • Posts: 291
  • Hero Points: 13
Re: Searching forward works, backwards won't find term
« Reply #4 on: October 29, 2016, 02:12:50 pm »
Search options were pretty much everything unchecked. Case insensitive. Searching for a class member variable where the text was camel case, something like m_FirstSecondThird. Not using regex.

Running on MAC OS/X. First time the error occurred was with 10.11.6 (OS X El Capitan), latest error was with Sierra with the latest patch (just updated Thursday, don't have the O/S numbers in front of me right now). The files I'm editing are on an NFS mount from a Linux machine to the MAC. The files are compiled on Linux so I always have to change Slick to use encoding of "Text, SBCD/DBCS mode" for all files of all extensions. I'm only using the MAC to edit the files, I use Linux to compile/etc.

I did see this problem in 20.0.x way back when. Then you guys fixed something and the problem went away. Now it is back with 21.0.0.12.

Clark

  • SlickEdit Team Member
  • Senior Community Member
  • *
  • Posts: 5092
  • Hero Points: 421
Re: Searching forward works, backwards won't find term
« Reply #5 on: October 29, 2016, 02:18:00 pm »
Thanks

I want to double check the encoding since it's important.

If you open a C++ file and display the save as dialog, what is the encoding?

rajkej

  • Senior Community Member
  • Posts: 291
  • Hero Points: 13
Re: Searching forward works, backwards won't find term
« Reply #6 on: October 29, 2016, 03:03:31 pm »
I'll have to do that Monday because the computer I do that on is inaccessible to me until then.

rajkej

  • Senior Community Member
  • Posts: 291
  • Hero Points: 13
Re: Searching forward works, backwards won't find term
« Reply #7 on: October 31, 2016, 01:19:54 pm »
When I open any .cpp file in my project space and then use 'save as', the file encoding is 'Text, SBCS/DBCS...'.

Here's the SE version info

SlickEdit Pro 2016 (v21.0.0.12)

Serial number:
Licensed number of users: Single user
License file: /Library/Application Support/SlickEdit/21/slickedit.lic

Build Date: October 26, 2016
Emulation: CUA

OS: macOS
OS Version: 10.12.1
Processor Architecture: Intel(R) Core(TM) i7-6700K CPU @ 4.00GHz 64 bit (8 cores)

Memory: 70% Load, 11620MB/16384MB Virtual
Shell Information: /Applications/SlickEditPro2016.app/Contents/MacOS/secsh -i
Screen Size: 2560 x 1440

Project Type: Cpp
Language: .cpp (C/C++)
Encoding: Automatic

Installation Directory: /Applications/SlickEditPro2016.app/Contents/
Configuration Directory: /Users/r/Library/Application Support/SlickEdit/21.0.0/
Migrated from: /Users/r/Library/Application Support/SlickEdit/20.0.3/
Spill File: /tmp/$slk.r.868

Hotfixes:
/Users/r/Library/Application Support/SlickEdit/21.0.0/hotfixes/hotfix_se2100_4_cumulative.zip (Revision: 4)