public inbox for sourcenav@sourceware.org
 help / color / mirror / Atom feed
* replace
@ 2001-06-29  7:02 Aurelian Melinte
  2001-07-03 13:12 ` replace Mo DeJong
  0 siblings, 1 reply; 16+ messages in thread
From: Aurelian Melinte @ 2001-06-29  7:02 UTC (permalink / raw)
  To: sourcenav

Hello,

Is there a way to change the name of a class or variable in all the source 
files at once?

What I mean is: If I want to change the name of a class from ClassA to 
NewClass, currently I grep through the files and then I edit all the 
findings , one by one. It there a better/faster way

Thanks,
A.


^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: replace
  2001-06-29  7:02 replace Aurelian Melinte
@ 2001-07-03 13:12 ` Mo DeJong
  2001-07-03 13:54   ` replace Gacquer William
  0 siblings, 1 reply; 16+ messages in thread
From: Mo DeJong @ 2001-07-03 13:12 UTC (permalink / raw)
  To: sourcenav

On Fri, 29 Jun 2001, Aurelian Melinte wrote:

> Hello,
> 
> Is there a way to change the name of a class or variable in all the source 
> files at once?

No, but that would be really cool. The question is, how to do this
in the GUI. Should it be part of the Grep tool? That would mean
grep would need to be modified to be a search and replace tool
instead of just a search tool. Would you be interested in doing
some hacking to add such a feature?

Mo DeJong
Red Hat Inc

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: replace
  2001-07-03 13:12 ` replace Mo DeJong
@ 2001-07-03 13:54   ` Gacquer William
  2001-07-03 14:45     ` replace Mo DeJong
  0 siblings, 1 reply; 16+ messages in thread
From: Gacquer William @ 2001-07-03 13:54 UTC (permalink / raw)
  To: Mo DeJong, sourcenav

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 918 bytes --]

I once wrote this but do not have the code anymore since I have left my last 
society. That was a bit tricky cos I had to play with flex. That was a 
command line tool.

As soon as I find some time to rewrite it, I'll contribute it to SN.

Just a question : was using flex a good idea? ( in fact, I was using it as if 
it was bison! )

William Gacquer
EKKLA Research 

Le Mardi  3 Juillet 2001 16:12, Mo DeJong a écrit :
> On Fri, 29 Jun 2001, Aurelian Melinte wrote:
> > Hello,
> >
> > Is there a way to change the name of a class or variable in all the
> > source files at once?
>
> No, but that would be really cool. The question is, how to do this
> in the GUI. Should it be part of the Grep tool? That would mean
> grep would need to be modified to be a search and replace tool
> instead of just a search tool. Would you be interested in doing
> some hacking to add such a feature?
>
> Mo DeJong
> Red Hat Inc

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: replace
  2001-07-03 13:54   ` replace Gacquer William
@ 2001-07-03 14:45     ` Mo DeJong
  2001-07-03 15:32       ` SN +gvim + ex-ctags == excellent free IDE Subrata Datta
  2001-07-03 18:37       ` replace (plain text) Berek Half-hand
  0 siblings, 2 replies; 16+ messages in thread
From: Mo DeJong @ 2001-07-03 14:45 UTC (permalink / raw)
  To: sourcenav

On Tue, 3 Jul 2001, Gacquer William wrote:

> I once wrote this but do not have the code anymore since I have left my last 
> society. That was a bit tricky cos I had to play with flex. That was a 
> command line tool.
> 
> As soon as I find some time to rewrite it, I'll contribute it to SN.
> 
> Just a question : was using flex a good idea? ( in fact, I was using it as if 
> it was bison! )
> 
> William Gacquer
> EKKLA Research 

Well, that is actually a bit different. I was talking about a global
text based find/replace. What you are talking about is a global
symbol aware find/replace. Both are important, but they are two
different solutions.

The symbol aware search and replace should be possible using the
existing symbol database. Running a search replace would consist
of:

1. Find the symbols in question.

2. Edit the file in question based on the info in the DB.
   (file name, line number, column start and column end)

3. Save the modified file.

4. Rinse, lather, repeat.

The good thing about this approach is that it makes use of
the existing parsers. The downside is that some nasty grubbing
around in the DB layer will be needed. Some hacking would be
required, but it would be a really cool feature.

Mo DeJong
Red Hat Inc

^ permalink raw reply	[flat|nested] 16+ messages in thread

* SN +gvim + ex-ctags == excellent free IDE
  2001-07-03 14:45     ` replace Mo DeJong
@ 2001-07-03 15:32       ` Subrata Datta
  2001-07-03 18:37       ` replace (plain text) Berek Half-hand
  1 sibling, 0 replies; 16+ messages in thread
From: Subrata Datta @ 2001-07-03 15:32 UTC (permalink / raw)
  To: sourcenav

Recently I started  using gvim, ex-ctags. I'm using SN for somtime.
If  you are doing c,C++ and assembly these combination of free
tools can beat any $$ IDE out there. Plus gvim/vi is highly 
customizable. I customized gvim right click menu and now can 
browse code clicking away. I noticed SN is slower compared to 
gvim/ctags.. but I guess these will be improved down the line.

sd


__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/

^ permalink raw reply	[flat|nested] 16+ messages in thread

* RE: replace (plain text)
  2001-07-03 14:45     ` replace Mo DeJong
  2001-07-03 15:32       ` SN +gvim + ex-ctags == excellent free IDE Subrata Datta
@ 2001-07-03 18:37       ` Berek Half-hand
  2001-07-03 22:54         ` Eric Christopher
  2001-07-04 11:49         ` Mo DeJong
  1 sibling, 2 replies; 16+ messages in thread
From: Berek Half-hand @ 2001-07-03 18:37 UTC (permalink / raw)
  To: sourcenav, Mo DeJong

Mo, just started work at Unisphere Networks in Westford Mass. Code base at
old place of work was all C++. Lots of parser and xref problems; you
probably remember some of my email. New job all JAVA. Dbimp croaks, can't
build xref, etc. My experience with SN is that it can't parse or build
xref's for anything but the simplest of standard C code bases. It doesn't
parse C++ or Java in any of the last three places I've worked at. And no, I
can't let you have any of the code bases (they don't belong to me). No, I
can't afford to pay Redstone to fix these problems (I paid $500 for SN 4.5.1
one month before it went public domain, and I sort of figured bug fixing and
maintenance were part of what I paid for). No, I can't fix these problems
myself; I spend all of my time (50-60 hrs/week) bringing home a paycheck.

So...instead of talking about code base search and replace, why doesn't
someone at RedHat fix some of these serious problems? I haven't been able to
get an xref of any code base in any language (except a simple std C grep I
wrote years ago) for over three years. Pardon my frustration, but I really
wish I had my money back. Any chance of that?

^ permalink raw reply	[flat|nested] 16+ messages in thread

* RE: replace (plain text)
  2001-07-03 18:37       ` replace (plain text) Berek Half-hand
@ 2001-07-03 22:54         ` Eric Christopher
  2001-07-04 11:49         ` Mo DeJong
  1 sibling, 0 replies; 16+ messages in thread
From: Eric Christopher @ 2001-07-03 22:54 UTC (permalink / raw)
  To: berek; +Cc: sourcenav

Berek,
    I know that since I work at Red Hat my comments on this will be
    quite suspect, however, I felt that since I've used SN on occasion
    that I should at least comment here.  SN has successfully parsed and
    xref'd the code to gcc, libstdc++ and many of the other programs
    that I work on here.  To be honest, I haven't tried this out much
    lately, but 3-6 mos ago when I last used the program it worked fine
    as an analysis tool.

    As a developer I'm sure that you only accept clear bug reports so
    that you can fix the problems.  The SN team I'm sure would
    appreciate them as well.  If you could provide code snippets that
    won't xref then they could verify the bugs and make sure that they
    work in the newer versions of the program.

    Now, as far as bug reports against old versions of the software,
    likely they'll be verified that they work in the new program and
    that you'll be suggested to upgrade to the newest version available
    from sources.  Have you tried doing this and does it work for you?

-eric

On 03 Jul 2001 21:37:49 -0400, Berek Half-hand wrote:
> Mo, just started work at Unisphere Networks in Westford Mass. Code base at
> old place of work was all C++. Lots of parser and xref problems; you
> probably remember some of my email. New job all JAVA. Dbimp croaks, can't
> build xref, etc. My experience with SN is that it can't parse or build
> xref's for anything but the simplest of standard C code bases. It doesn't
> parse C++ or Java in any of the last three places I've worked at. And no, I
> can't let you have any of the code bases (they don't belong to me). No, I
> can't afford to pay Redstone to fix these problems (I paid $500 for SN 4.5.1
> one month before it went public domain, and I sort of figured bug fixing and
> maintenance were part of what I paid for). No, I can't fix these problems
> myself; I spend all of my time (50-60 hrs/week) bringing home a paycheck.
> 
> So...instead of talking about code base search and replace, why doesn't
> someone at RedHat fix some of these serious problems? I haven't been able to
> get an xref of any code base in any language (except a simple std C grep I
> wrote years ago) for over three years. Pardon my frustration, but I really
> wish I had my money back. Any chance of that?
> 

-- 
I will not grease the monkey bars

^ permalink raw reply	[flat|nested] 16+ messages in thread

* RE: replace (plain text)
  2001-07-03 18:37       ` replace (plain text) Berek Half-hand
  2001-07-03 22:54         ` Eric Christopher
@ 2001-07-04 11:49         ` Mo DeJong
  2001-07-04 12:09           ` Berek Half-hand
                             ` (2 more replies)
  1 sibling, 3 replies; 16+ messages in thread
From: Mo DeJong @ 2001-07-04 11:49 UTC (permalink / raw)
  To: sourcenav

On Tue, 3 Jul 2001, Berek Half-hand wrote:

...

> So...instead of talking about code base search and replace, why doesn't
> someone at RedHat fix some of these serious problems? I haven't been able to
> get an xref of any code base in any language (except a simple std C grep I
> wrote years ago) for over three years. Pardon my frustration, but I really
> wish I had my money back. Any chance of that?

Frankly, I am not sure how to respond to your email. I seem to remember
explaining options that folks had when faced with a bug on this list
a number of times. Whining about a bug is not really the most effective
course of action.

Just because you don't see any improvement in a specific set of bugs
does not mean that we are not fixing things. Currently, we are working
on the Tcl/Tk 8.3 upgrade and getting CVS access setup. This work
is much more important then the parsers. The parsers need work, it
is a know issue and it is likely one that will never be solved to
everyone's satisfaction (since everyone wants something different).

Mo DeJong
Red Hat Inc

^ permalink raw reply	[flat|nested] 16+ messages in thread

* RE: replace (plain text)
  2001-07-04 11:49         ` Mo DeJong
@ 2001-07-04 12:09           ` Berek Half-hand
  2001-07-04 15:11             ` Eric Christopher
  2001-07-04 13:52           ` Gacquer William
  2001-07-06 13:41           ` Andrew Cagney
  2 siblings, 1 reply; 16+ messages in thread
From: Berek Half-hand @ 2001-07-04 12:09 UTC (permalink / raw)
  To: sourcenav

You refer to the fact that SN is incapable of producing a xref for any of
the C++ and Java code bases I've worked on for the past 3 1/2 years as "a
bug"? That it's not as important as upgrading to TCL/TK 8.3? Frankly, IMHO,
the xref capability of SN is by far the most important feature of the
product. Of all the tools that allow people to come up to speed on a new
code base and for understanding new and existing functionality, the xref is
by far the most useful and important. I've only seen SN xref work on the
most trivial of code bases. You call this "whining" [smile]? And, BTW, it's
not one bug. it's many.

I just sent a small part of my latest code base to a cohort of yours in the
UK. I included screen captures of a couple of bugs, including (MS Visual
Studio) memory, registers, error messages, disassembly at the location of
the error (access violation in dbimp) and all of the source code he needed
to reproduce and solve the problem. His response was that it was too much
info for him to download and that he was reluctant to receive source code
that didn't belong to me (it belongs to my employers). He then asked me if I
could provide him with an "example" of the source code that caused the
problem [AAAAARRRRRGGGGGHHHHH!!!!!]. Is there something wrong with this or
is it me?

-----Original Message-----
From: sourcenav-owner@sources.redhat.com
[ mailto:sourcenav-owner@sources.redhat.com]On Behalf Of Mo DeJong
Sent: Wednesday, July 04, 2001 2:49 PM
To: sourcenav@sourceware.cygnus.com
Subject: RE: replace (plain text)


On Tue, 3 Jul 2001, Berek Half-hand wrote:

....

> So...instead of talking about code base search and replace, why doesn't
> someone at RedHat fix some of these serious problems? I haven't been able
to
> get an xref of any code base in any language (except a simple std C grep I
> wrote years ago) for over three years. Pardon my frustration, but I really
> wish I had my money back. Any chance of that?

Frankly, I am not sure how to respond to your email. I seem to remember
explaining options that folks had when faced with a bug on this list
a number of times. Whining about a bug is not really the most effective
course of action.

Just because you don't see any improvement in a specific set of bugs
does not mean that we are not fixing things. Currently, we are working
on the Tcl/Tk 8.3 upgrade and getting CVS access setup. This work
is much more important then the parsers. The parsers need work, it
is a know issue and it is likely one that will never be solved to
everyone's satisfaction (since everyone wants something different).

Mo DeJong
Red Hat Inc


^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: replace (plain text)
  2001-07-04 11:49         ` Mo DeJong
  2001-07-04 12:09           ` Berek Half-hand
@ 2001-07-04 13:52           ` Gacquer William
  2001-07-04 14:38             ` Mo DeJong
  2001-07-06 13:41           ` Andrew Cagney
  2 siblings, 1 reply; 16+ messages in thread
From: Gacquer William @ 2001-07-04 13:52 UTC (permalink / raw)
  To: Mo DeJong, sourcenav

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1518 bytes --]

Just a word about the cygnus CVS tree. Do you keep it secret cos your 
customers asked for custom developments that are visible in some cygnus tree 
branches? ( as Sony did for its Playstation 2 SDK, for instance, but that was 
a Cygnus Japan work )

Having access to the whole tree would greatly simplify a lot of things for 
us. 

William Gacquer

Le Mercredi  4 Juillet 2001 14:49, Mo DeJong a écrit :
> On Tue, 3 Jul 2001, Berek Half-hand wrote:
>
> ...
>
> > So...instead of talking about code base search and replace, why doesn't
> > someone at RedHat fix some of these serious problems? I haven't been able
> > to get an xref of any code base in any language (except a simple std C
> > grep I wrote years ago) for over three years. Pardon my frustration, but
> > I really wish I had my money back. Any chance of that?
>
> Frankly, I am not sure how to respond to your email. I seem to remember
> explaining options that folks had when faced with a bug on this list
> a number of times. Whining about a bug is not really the most effective
> course of action.
>
> Just because you don't see any improvement in a specific set of bugs
> does not mean that we are not fixing things. Currently, we are working
> on the Tcl/Tk 8.3 upgrade and getting CVS access setup. This work
> is much more important then the parsers. The parsers need work, it
> is a know issue and it is likely one that will never be solved to
> everyone's satisfaction (since everyone wants something different).
>
> Mo DeJong
> Red Hat Inc

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: replace (plain text)
  2001-07-04 13:52           ` Gacquer William
@ 2001-07-04 14:38             ` Mo DeJong
  2001-07-04 15:10               ` Gacquer William
  0 siblings, 1 reply; 16+ messages in thread
From: Mo DeJong @ 2001-07-04 14:38 UTC (permalink / raw)
  To: sourcenav

On Wed, 4 Jul 2001, Gacquer William wrote:

> Just a word about the cygnus CVS tree. Do you keep it secret cos your 
> customers asked for custom developments that are visible in some cygnus tree 
> branches? ( as Sony did for its Playstation 2 SDK, for instance, but that was 
> a Cygnus Japan work )
> 
> Having access to the whole tree would greatly simplify a lot of things for 
> us. 

The thing holding up CVS access is that fact that we have to get
both GDB and Source-Navigator upgraded to Tcl/Tk 8.3 before
they can exist in the same CVS repo on sources.redhat.com.

If you take a look at the current CVS module for Insight
you will note that it uses Tcl/Tk 8.0.

http://sources.redhat.com/insight/

Source-Navigator makes use of Tcl/Tk 8.1.

Once both Insight and Source-Navigator use the same version
of Tcl/Tk, we can add Source-Navigator to the CVS.

Mo

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: replace (plain text)
  2001-07-04 14:38             ` Mo DeJong
@ 2001-07-04 15:10               ` Gacquer William
  2001-07-05 18:21                 ` Mo DeJong
  0 siblings, 1 reply; 16+ messages in thread
From: Gacquer William @ 2001-07-04 15:10 UTC (permalink / raw)
  To: Mo DeJong, sourcenav

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1188 bytes --]

I played a lot with DDD, GVD and Insight while developing for the PlayStation 
2 target. I have to say that insight is not very stable.
Do you plan to allow debug sessions from SN instead of having to launch 
insight?

William

Le Mercredi  4 Juillet 2001 17:38, Mo DeJong a écrit :
> On Wed, 4 Jul 2001, Gacquer William wrote:
> > Just a word about the cygnus CVS tree. Do you keep it secret cos your
> > customers asked for custom developments that are visible in some cygnus
> > tree branches? ( as Sony did for its Playstation 2 SDK, for instance, but
> > that was a Cygnus Japan work )
> >
> > Having access to the whole tree would greatly simplify a lot of things
> > for us.
>
> The thing holding up CVS access is that fact that we have to get
> both GDB and Source-Navigator upgraded to Tcl/Tk 8.3 before
> they can exist in the same CVS repo on sources.redhat.com.
>
> If you take a look at the current CVS module for Insight
> you will note that it uses Tcl/Tk 8.0.
>
> http://sources.redhat.com/insight/
>
> Source-Navigator makes use of Tcl/Tk 8.1.
>
> Once both Insight and Source-Navigator use the same version
> of Tcl/Tk, we can add Source-Navigator to the CVS.
>
> Mo

^ permalink raw reply	[flat|nested] 16+ messages in thread

* RE: replace (plain text)
  2001-07-04 12:09           ` Berek Half-hand
@ 2001-07-04 15:11             ` Eric Christopher
  2001-07-09  7:17               ` Aurelian Melinte
  0 siblings, 1 reply; 16+ messages in thread
From: Eric Christopher @ 2001-07-04 15:11 UTC (permalink / raw)
  To: berek; +Cc: sourcenav

> most trivial of code bases. You call this "whining" [smile]? And, BTW, it's
> not one bug. it's many.
> 

That's the problem.  We don't know if it one or more without a good
testcase...

> I just sent a small part of my latest code base to a cohort of yours in the
> UK. I included screen captures of a couple of bugs, including (MS Visual
> Studio) memory, registers, error messages, disassembly at the location of
> the error (access violation in dbimp) and all of the source code he needed
> to reproduce and solve the problem. His response was that it was too much
> info for him to download and that he was reluctant to receive source code
> that didn't belong to me (it belongs to my employers). He then asked me if I
> could provide him with an "example" of the source code that caused the
> problem [AAAAARRRRRGGGGGHHHHH!!!!!]. Is there something wrong with this or
> is it me?

It is just you, of course, being that cohort I can't comment for anyone
else ;)  Without the code being released by your company via a written
release I can't look at it.  The best example is, of course, what you
sent me.  However, without a release from your company no one at Red Hat
can look at it.  If you can perhaps come up with a contrived example
that evokes the same behavior it would be wonderful.  As far as it being
too big, I work on the compiler most of the time - testcases are usually
small :)

-eric

-- 
I will not grease the monkey bars

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: replace (plain text)
  2001-07-04 15:10               ` Gacquer William
@ 2001-07-05 18:21                 ` Mo DeJong
  0 siblings, 0 replies; 16+ messages in thread
From: Mo DeJong @ 2001-07-05 18:21 UTC (permalink / raw)
  To: sourcenav

On Thu, 5 Jul 2001, Gacquer William wrote:

> I played a lot with DDD, GVD and Insight while developing for the PlayStation 
> 2 target. I have to say that insight is not very stable.
> Do you plan to allow debug sessions from SN instead of having to launch 
> insight?
> 
> William

There had been quite a bit of talk about implementing a MI
based interface to gdb inside SN. It would be based on
the new MI interface in gdb, which would solve the
stability problem that Insight suffers from. Thing is,
it is mostly talk at this point. It would really help
if we had a customer that was willing to fund development
of this feature.

Mo DeJong
Red Hat Inc

^ permalink raw reply	[flat|nested] 16+ messages in thread

* Re: replace (plain text)
  2001-07-04 11:49         ` Mo DeJong
  2001-07-04 12:09           ` Berek Half-hand
  2001-07-04 13:52           ` Gacquer William
@ 2001-07-06 13:41           ` Andrew Cagney
  2 siblings, 0 replies; 16+ messages in thread
From: Andrew Cagney @ 2001-07-06 13:41 UTC (permalink / raw)
  To: Mo DeJong; +Cc: sourcenav

> Just because you don't see any improvement in a specific set of bugs
> does not mean that we are not fixing things. Currently, we are working
> on the Tcl/Tk 8.3 upgrade and getting CVS access setup. This work
> is much more important then the parsers. The parsers need work, it
> is a know issue and it is likely one that will never be solved to
> everyone's satisfaction (since everyone wants something different).


Mo, for what its worth. Good luck to you and the other SN people trying 
to complete this task.  Unlike a parser bug which might annoy one or two 
individuals, this is hurting everyone.

	Andrew

^ permalink raw reply	[flat|nested] 16+ messages in thread

* RE: replace (plain text)
  2001-07-04 15:11             ` Eric Christopher
@ 2001-07-09  7:17               ` Aurelian Melinte
  0 siblings, 0 replies; 16+ messages in thread
From: Aurelian Melinte @ 2001-07-09  7:17 UTC (permalink / raw)
  To: sourcenav

[-- Attachment #1: Type: text/plain, Size: 327 bytes --]

Hello,

here's the modified greppane that includes the replace functionality. It is 
based on the SN50-010322 sources. I tested it with a bunch of simple 
replacements and all went well. If you are unhappy with the replacement 
results, just recover the .noreplace file that was created before the 
actual replace.

Thanks,
A.

[-- Attachment #2: replace.zip --]
[-- Type: application/zip, Size: 25693 bytes --]

^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2001-07-09  7:17 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-06-29  7:02 replace Aurelian Melinte
2001-07-03 13:12 ` replace Mo DeJong
2001-07-03 13:54   ` replace Gacquer William
2001-07-03 14:45     ` replace Mo DeJong
2001-07-03 15:32       ` SN +gvim + ex-ctags == excellent free IDE Subrata Datta
2001-07-03 18:37       ` replace (plain text) Berek Half-hand
2001-07-03 22:54         ` Eric Christopher
2001-07-04 11:49         ` Mo DeJong
2001-07-04 12:09           ` Berek Half-hand
2001-07-04 15:11             ` Eric Christopher
2001-07-09  7:17               ` Aurelian Melinte
2001-07-04 13:52           ` Gacquer William
2001-07-04 14:38             ` Mo DeJong
2001-07-04 15:10               ` Gacquer William
2001-07-05 18:21                 ` Mo DeJong
2001-07-06 13:41           ` Andrew Cagney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).