473,395 Members | 1,608 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Searching for a C++ code browser which will....

I've recently moved onto a C++ project with a large number of directories
(several hundred) containing an even larger number of C++ source files.

There are vastly more ways in C++ to obfuscate a program than there are
in C, and it seems somebody laid a bet on the original development team
to prove that this is the case. ;-( Unfortunately, I have no contact
with the original programmers, who live and work on a different
continent.

In the course of tracking down a bug, I need a browser which can tell me
all the places in the code where `ClimbMountain', as in:

Arizona::ClimbMountain (*crevasse lookout) ;

gets called. That is, I want the browser to identify lines of code like

*state.phoenix[i]->ClimbMountain (Hoi) ;

, because `phoenix' here is an array of Arizona pointers. However, I
want this browser to _avoid_ telling me about lines like

*state.StPaul[i].ClimbMountain (Hi) ;

, because the StPaul in that line is an array of Minnesotas, not an array
of Arizonas. Needless to say, there is no chain of inheritance between
the classes Minnesota and Arizona - at least, none that I'm aware of, but
since there is a great deal of multiple inheritance used within the
program, I could be wrong.

I tried downloading SourceNav from SourceForge yesterday. The
documentation's list of SourceNav's capabilities is somewhat on the vague
side, so I therefore tried the program out - unless I'm mistaken, this
browser can only tell me that `ClimbMountain' is "used" in the definition
of the class `Arizona', not the places where instances of Arizona invoke
`ClimbMountain'.

Does there exist a C++ browser (preferably free or open-source running
on MS-Windows or on Unices), powerful enough to give me the info I need?
If so, please tell me its name and its URL.

Thanks in advance for the help!

--
Alan Mackenzie (Munich, Germany)
Email: aa**@muuc.dee; to decode, wherever there is a repeated letter
(like "aa"), remove half of them (leaving, say, "a").

Jul 22 '05 #1
5 5373
I use Source Insight http://www.sourceinsight.com

++PLS

In article <eg**********@acm.acm>, ac*@muc.de says...
I've recently moved onto a C++ project with a large number of directories
(several hundred) containing an even larger number of C++ source files.

There are vastly more ways in C++ to obfuscate a program than there are
in C, and it seems somebody laid a bet on the original development team
to prove that this is the case. ;-( Unfortunately, I have no contact
with the original programmers, who live and work on a different
continent.

In the course of tracking down a bug, I need a browser which can tell me
all the places in the code where `ClimbMountain', as in:

Arizona::ClimbMountain (*crevasse lookout) ;

gets called. That is, I want the browser to identify lines of code like

*state.phoenix[i]->ClimbMountain (Hoi) ;

, because `phoenix' here is an array of Arizona pointers. However, I
want this browser to _avoid_ telling me about lines like

*state.StPaul[i].ClimbMountain (Hi) ;

, because the StPaul in that line is an array of Minnesotas, not an array
of Arizonas. Needless to say, there is no chain of inheritance between
the classes Minnesota and Arizona - at least, none that I'm aware of, but
since there is a great deal of multiple inheritance used within the
program, I could be wrong.

I tried downloading SourceNav from SourceForge yesterday. The
documentation's list of SourceNav's capabilities is somewhat on the vague
side, so I therefore tried the program out - unless I'm mistaken, this
browser can only tell me that `ClimbMountain' is "used" in the definition
of the class `Arizona', not the places where instances of Arizona invoke
`ClimbMountain'.

Does there exist a C++ browser (preferably free or open-source running
on MS-Windows or on Unices), powerful enough to give me the info I need?
If so, please tell me its name and its URL.

Jul 22 '05 #2
I think find&replace with a regex string can do it.. Bot VC++ and Metrowerks
Codewarrior supports these...

"Alan Mackenzie" <ac*@muc.de> wrote in message news:eg**********@acm.acm...
I've recently moved onto a C++ project with a large number of directories
(several hundred) containing an even larger number of C++ source files.

There are vastly more ways in C++ to obfuscate a program than there are
in C, and it seems somebody laid a bet on the original development team
to prove that this is the case. ;-( Unfortunately, I have no contact
with the original programmers, who live and work on a different
continent.

In the course of tracking down a bug, I need a browser which can tell me
all the places in the code where `ClimbMountain', as in:

Arizona::ClimbMountain (*crevasse lookout) ;

gets called. That is, I want the browser to identify lines of code like

*state.phoenix[i]->ClimbMountain (Hoi) ;

, because `phoenix' here is an array of Arizona pointers. However, I
want this browser to _avoid_ telling me about lines like

*state.StPaul[i].ClimbMountain (Hi) ;

, because the StPaul in that line is an array of Minnesotas, not an array
of Arizonas. Needless to say, there is no chain of inheritance between
the classes Minnesota and Arizona - at least, none that I'm aware of, but
since there is a great deal of multiple inheritance used within the
program, I could be wrong.

I tried downloading SourceNav from SourceForge yesterday. The
documentation's list of SourceNav's capabilities is somewhat on the vague
side, so I therefore tried the program out - unless I'm mistaken, this
browser can only tell me that `ClimbMountain' is "used" in the definition
of the class `Arizona', not the places where instances of Arizona invoke
`ClimbMountain'.

Does there exist a C++ browser (preferably free or open-source running
on MS-Windows or on Unices), powerful enough to give me the info I need?
If so, please tell me its name and its URL.

Thanks in advance for the help!

--
Alan Mackenzie (Munich, Germany)
Email: aa**@muuc.dee; to decode, wherever there is a repeated letter
(like "aa"), remove half of them (leaving, say, "a").

Jul 22 '05 #3
In message <41***********************@nntp05.dk.telia.net>, Jesper
Madsen <ba***@mail.stofanet.dk> top-posted

"Alan Mackenzie" <ac*@muc.de> wrote in message news:eg**********@acm.acm...

. That is, I want the browser to identify lines of code like

*state.phoenix[i]->ClimbMountain (Hoi) ;

, because `phoenix' here is an array of Arizona pointers. However, I
want this browser to _avoid_ telling me about lines like

*state.StPaul[i].ClimbMountain (Hi) ;

, because the StPaul in that line is an array of Minnesotas, not an array
of Arizonas. Needless to say, there is no chain of inheritance between
the classes Minnesota and Arizona - at least, none that I'm aware of, but
since there is a great deal of multiple inheritance used within the
program, I could be wrong.
[...]

I think find&replace with a regex string can do it.. Bot VC++ and Metrowerks
Codewarrior supports these...


You have a remarkable implementation of regex if it can distinguish
between the two ClimbMountain lines above.
--
Richard Herring
Jul 22 '05 #4
Paul Schauble <pl*@thekeep.com> wrote on Sun, 5 Sep 2004 03:52:42 -0700:
In article <eg**********@acm.acm>, ac*@muc.de says...
I've recently moved onto a C++ project with a large number of directories
(several hundred) containing an even larger number of C++ source files. There are vastly more ways in C++ to obfuscate a program than there are
in C, and it seems somebody laid a bet on the original development team
to prove that this is the case. ;-( Unfortunately, I have no contact
with the original programmers, who live and work on a different
continent. In the course of tracking down a bug, I need a browser which can tell me
all the places in the code where `ClimbMountain', as in: Arizona::ClimbMountain (*crevasse lookout) ; gets called. That is, I want the browser to identify lines of code like *state.phoenix[i]->ClimbMountain (Hoi) ; , because `phoenix' here is an array of Arizona pointers. However, I
want this browser to _avoid_ telling me about lines like *state.StPaul[i].ClimbMountain (Hi) ; , because the StPaul in that line is an array of Minnesotas, not an array
of Arizonas. Needless to say, there is no chain of inheritance between
the classes Minnesota and Arizona - at least, none that I'm aware of, but
since there is a great deal of multiple inheritance used within the
program, I could be wrong. I tried downloading SourceNav from SourceForge yesterday. The
documentation's list of SourceNav's capabilities is somewhat on the vague
side, so I therefore tried the program out - unless I'm mistaken, this
browser can only tell me that `ClimbMountain' is "used" in the definition
of the class `Arizona', not the places where instances of Arizona invoke
`ClimbMountain'. Does there exist a C++ browser (preferably free or open-source running
on MS-Windows or on Unices), powerful enough to give me the info I need?
If so, please tell me its name and its URL.
I use Source Insight http://www.sourceinsight.com
I've been trying the trial version of Source Insight in an odd few hours
over the last week. Sadly, SI appears to do little more than crude
grepping through the all the sources. I've got a Posix system handy
where I can do all my grepping directly anyway, so SI's searching doesn't
really give me much extra. When I ask it to find
"Arizona.ClimbMountain", it merely finds the appropriate _declaration_ of
ClimbMountain. This is a pity, because on opening up (almost) any source
file, and hovering the mouse over the pertinent place, it displays the
type of the variable. I find this too cumbersome for the searching I
need to do.

Our sources are even worse than I thought. There are _lots_ of
identifiers with names like "DoIt" which are distinguished only by being
in different namespaces. YUCK! SI can't distinguish these either.

[<rant mode> Why on earth are the various designers of C++ so opposed to
context-free identifiers? OK, C had context-dependant identifiers a bit
(members of a struct or union), and C++ classes are an extension of this.
But namespaces? sheesh! These designers must have really _hated_ us
poor maintenance programmers ;-) <\rant mode>]

Anyhow, I sent an email to SourceInsight, asking them to consider
enhancing their product.

Thanks for the suggestion.
++PLS


--
Alan Mackenzie (Munich, Germany)
Email: aa**@muuc.dee; to decode, wherever there is a repeated letter
(like "aa"), remove half of them (leaving, say, "a").

Jul 22 '05 #5
Alan Mackenzie wrote:
I use Source Insight http://www.sourceinsight.com

I've been trying the trial version of Source Insight in an odd few hours
over the last week. Sadly, SI appears to do little more than crude
grepping through the all the sources. I've got a Posix system handy
where I can do all my grepping directly anyway, so SI's searching doesn't
really give me much extra. When I ask it to find
"Arizona.ClimbMountain", it merely finds the appropriate _declaration_ of
ClimbMountain. This is a pity, because on opening up (almost) any source
file, and hovering the mouse over the pertinent place, it displays the
type of the variable. I find this too cumbersome for the searching I
need to do.

Our sources are even worse than I thought. There are _lots_ of
identifiers with names like "DoIt" which are distinguished only by being
in different namespaces. YUCK! SI can't distinguish these either.

[<rant mode> Why on earth are the various designers of C++ so opposed to
context-free identifiers? OK, C had context-dependant identifiers a bit
(members of a struct or union), and C++ classes are an extension of this.
But namespaces? sheesh! These designers must have really _hated_ us
poor maintenance programmers ;-) <\rant mode>]

Anyhow, I sent an email to SourceInsight, asking them to consider
enhancing their product.

Thanks for the suggestion.

++PLS


I've had really good luck with Doxygen (http://www.doxygen.org -- it's
free!), and Understand for C++ (http://www.scitools.com/ucpp.html). Try
em both.
Jul 22 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: Adrian | last post by:
This script works well for searching thru a SELECT list but doesnt work so well with the MULTIPLE option. I need to modify it to work for a SELECT MULTIPLE but I have no idea where to begin, any...
0
by: Mike | last post by:
Sites using thumbnail preview for world wide web file navigation and searching. Below are list of sites that are either researching or providing thumbnail preview images for online web...
14
by: Ludwig77 | last post by:
I read that there are some tags that can be entered in a web page's meta tags in order to prevent web bot searching and indexing of the web page for search engines. What is the tagging that I...
3
by: Paul H | last post by:
I have a text file that contains the following: ******************** __StartCustomerID_41 Name: Fred Smith Address: 57 Pew Road Croydon
33
by: Geoff Jones | last post by:
Hiya I have a DataTable containing thousands of records. Each record has a primary key field called "ID" and another field called "PRODUCT" I want to retrieve the rows that satisy the following...
7
by: Andrea | last post by:
Hi there - I'm hoping someone can help me; I've been struggling with this for a few days! :-) I have a webpage that is comprised of many forms containing questions. As the user answers one...
4
by: Jordan S. | last post by:
Using .NET 2.0 (C#) I'm writing a small app that will have a "Person" class that exposes FirstName and LastName properties. At runtime, a "People" collection will be populated with a few thousand...
5
by: lemlimlee | last post by:
hello, this is the task i need to do: For this task, you are to develop a Java program that allows a user to search or sort an array of numbers using an algorithm that the user chooses. The...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.