tags:

views:

126

answers:

3

I'm tired of copy pasting the header into my cpp file then hacking at it until its in the correct form. Has anyone made a program to read a header file and make a corresponding cpp skeleton?

Who else wishes D was older and more stable? We should strike C++ from the records!!!!

Example

class A
{
    public:
        int DoSomething( int number );
}

Would produce the following file

int A::DoSomething( int number )
{
    ;
}
+1  A: 

You can try to play around with LazyCplusplus. Or you can try out Visual Assist X for Visual Studio.

Instead of strinking C++ from the records, I'd rather wait for C++ promised modules. :)

Edit : actually this seems a duplicate of your question : http://stackoverflow.com/questions/2020568/seeking-code-stub-generator-from-header-files

Kornel Kisielewicz
English has to many words to describe the same thing /facepalm
Buttink
+1 for lzz. It's the business.
Richard Corden
How I wish the modules came :x
Matthieu M.
A: 

Almost every IDE has built-in features or plugins that do that for you - e.g. for Visual Studio Visual Assist X provides many convenience features.
There are also many code generation utilities, you could also create one use yourself using e.g. gcc-xml and the scripting language of your choice.

We should strike C++ from the records!!!!

Euh, no.

Georg Fritzsche
+1  A: 

http://www.vim.org/scripts/script.php?script_id=2624

Kniganapolke
omg there is a vim plugin to do this i <3 you
Buttink