Author |
Topic |
|
xreborner
New Member
2 Posts |
Posted - Aug 23 2007 : 07:01:34 AM
|
I think it will be very useful to reorder the member functions' definitions in source file according to their declarations in class definition in header file. So that when we have created several implementations or moved several implementations to source file, we can simply reorder them at once. |
|
feline
Whole Tomato Software
United Kingdom
19021 Posts |
Posted - Aug 23 2007 : 07:42:23 AM
|
If you are looking for an easy manual way of doing this you can turn on VA Outline, which is currently a beta feature. See here for details:
http://forum.wholetomato.com/forum/topic.asp?TOPIC_ID=6149
We have considered some method of doing this automatically, but it runs into all sorts of problems, especially since you cannot assume that the header and cpp files are currently in the same order. |
zen is the art of being at one with the two'ness |
|
|
xreborner
New Member
2 Posts |
Posted - Aug 23 2007 : 08:33:17 AM
|
I know VA Outline. But it still needs many operations to reorder all member functions.
As you have implemented VA Outline, can you add a command on it that reorders the member functions in source file, so that the user need not manually reorder them by multiple drags and drops on VA Outline?
Or, consider implementing a command, which embeds all implementions in source file into the class definition in header file (and also remove the implementions in source file). This helps user to browse the code in a more convenient way, although the code may be not comiplable. And then the user can manually move definitions to source file in order, which should be much easier than manually reorder them in the source file.
quote: Originally posted by feline
If you are looking for an easy manual way of doing this you can turn on VA Outline, which is currently a beta feature. See here for details:
http://forum.wholetomato.com/forum/topic.asp?TOPIC_ID=6149
We have considered some method of doing this automatically, but it runs into all sorts of problems, especially since you cannot assume that the header and cpp files are currently in the same order.
|
|
|
feline
Whole Tomato Software
United Kingdom
19021 Posts |
Posted - Aug 23 2007 : 12:16:47 PM
|
Reliably inlining functions would be difficult, since VA does not fully understand overloaded functions. It knows that a function is overloaded, but it does no know which overload is which.
Having VA Outline sort all children of a node is possible, but if anything this is likely to make things worse, since suddenly the cpp and .h files will be even more different when it comes to file ordering.
Remember that in the header file the class has public, protected and private nodes.
For now reordering the files manually as you work on them is probably the best solution. |
zen is the art of being at one with the two'ness |
|
|
|
Topic |
|