Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Sep 14th, 2007, 10:02 PM   #1
Dameon
Troll
 
Dameon's Avatar
 
Join Date: Apr 2005
Location: Texas
Posts: 732
Rep Power: 4 Dameon is on a distinguished road
Tedious headers

I haven't seen a way in Visual C++ 2005 to stub members defined in headers or synchronize changes between header and source (like changing return type or adding a parameter). Surely there is a way to automate this. Why should I have to waste time copying things between files? I must be missing something.

Perhaps Eclipse or some other sane IDE can do this?
__________________
MD5(sig) = bcef75433db02e9ad9bf81d6f7c5c270
Dameon is offline   Reply With Quote
Old Sep 15th, 2007, 10:06 PM   #2
Dameon
Troll
 
Dameon's Avatar
 
Join Date: Apr 2005
Location: Texas
Posts: 732
Rep Power: 4 Dameon is on a distinguished road
Anyone? This redundancy is killing me.
__________________
MD5(sig) = bcef75433db02e9ad9bf81d6f7c5c270
Dameon is offline   Reply With Quote
Old Sep 16th, 2007, 4:15 AM   #3
grumpy
Programming Guru
 
grumpy's Avatar
 
Join Date: Jun 2005
Location: Adelaide, South Australia
Posts: 1,209
Rep Power: 5 grumpy is on a distinguished road
I didn't answer before because I wasn't sure what you're getting at. Are you asking for a feature of your development environment, so that when you change the declaration of a function in a header it magically updates the implementation of the function to match the declaration? And vice versa?

If so, I've yet to come across an IDE that does this for arbitrary code (as that would mean the editor would need to separately keep track of the relationship between a declaration in a header and the implementation in a source file). For some specialised IDEs (eg graphical "drag and drop" GUI designers) it happens with the code that the IDE automatically generates. That only works because the developer is prevented (or strongly discouraged) from hand-modifying the parts of the code that are automatically generated by the IDE.
grumpy is offline   Reply With Quote
Old Sep 25th, 2007, 11:09 PM   #4
The Dark
Expert Programmer
 
Join Date: Jun 2005
Posts: 825
Rep Power: 4 The Dark is on a distinguished road
I just installed Refactor!
This is a free version of their full product, but it supports variable and member renames as well as many other nice refactoring features.
I haven't used it much yet, but it looks like it works pretty well. I'm not sure it does adding a parameter or changing return type though.

PS. I saw it on the Start Page of Visual Studio, so that damn thing is useful sometimes.
The Dark is offline   Reply With Quote
Old Sep 26th, 2007, 7:40 PM   #5
Seif
Hobbyist Programmer
 
Seif's Avatar
 
Join Date: Jan 2006
Location: UK
Posts: 214
Rep Power: 3 Seif is on a distinguished road
I use a tool called StarUML to generate the member bodies for my classes. Has been pretty tidy for what I need. Also adds inclusion guards which Visual Studio doesn't seem to be able to do. Though Admittidly, I gave up trying to look through the waffle produced by a google search.

Another cool thing about this tool I found is that it can reverse engineer existing code bases. Oh and it can also do the same with C# and Java languages.

I guess one draw back is that it will be annoying to have to include the files into your C++ IDE manually. That said however, you'd be implementing some good engineering practices using uml.

linky:

http://staruml.sourceforge.net/en/
Seif is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Premature end of script headers amon C++ 13 May 14th, 2005 6:58 AM




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 12:14 AM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC