Search Results

Search: Posts Made By: offkilter
8,845
Posted By offkilter
vbe, I tried Anbu23's syntax by itself and...
vbe,

I tried Anbu23's syntax by itself and it found too many non-matching lines. I tried it combined with what I had (adding in the [^=] before =)

egrep "^if\b*\(.+[^=]=[^=]*" *.cpp

but it...
8,845
Posted By offkilter
doesn't work
Anbu23,
Thanks, but this finds != in if statements and lines with variable names that have 'if' in them.

---------- Post updated at 11:50 AM ---------- Previous update was at 11:35 AM ----------...
8,845
Posted By offkilter
grep regular expression to find = not ==
I suspect this is commonly done, but haven't found the right combination of search terms to find the answer.

I want to grep for lines in .cpp files that contain only 1 '=' sign in an if...
Showing results 1 to 3 of 3

 
All times are GMT -4. The time now is 12:55 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy