Made a tool you C++ guys may be interested in

Started by
23 comments, last by dominicoder 18 years, 10 months ago
Hey peeps, So I got tired of C & P'ing code and / or starting from scratch when writing source and header files so ... I made a program to do it for me! I thought I'd post here, get some feedback, and see if anyone would find it useful. You can find it at this incredibly lame page (put together in 5 minutes ... quite literally [grin]) http://www.rit.edu/~ldr2567/ClassMaker/ . It's a C# Winforms app so most of you should be able to run it. Let me know what you think. Any problems? Glaring problems in the C++ syntax? Noticable bugs I may have missed? Suggestions? Anything you would add? Remove? Change? Find it useful at all? Would you use it? You get the picture ... :) Thanks
Advertisement
I was unable to get the tool to run, but from the screenshots I would say it offers an advantage over the built in class creation toolset in VS.NET :) If you cleaned it up and made it an add-in for VS.NET/Slickedit/Eclipse it would be a pretty cool tool. The problem besides it not running is the fact that its a seperate executable and it may be faster to just type out the file yourself unless it was a very complex definition and then program might save you a few seconds.
Hmm ... what error did you get when trying to run?
The window never showed up. I ran it with and without any firewall/av present. It may have something to do with my configuration. I liked the screenshots though.

My Config:P4 2.4ghz1gb RamWindows XP SP2Radeon 9800All Libraries from a default VS.NET/.NET2.0/.NET1.1 install are present
i got it, and it ran fine for me.
Quote:Original post by Undergamer
... It may have something to do with my configuration. ...


Looks good. Much better than the one provided by VS.NET 2003.

There's just a few suggestions I have:

(1) Support for inline files (either by adding a .inl or having all code in the .h file)

(2) I can specify a templated class, but I can not specify to inherit from a templated class. The syntax for inheriting from templated classes is slightly different than inheriting from non-templated classes.

Also, I think the generated syntax for C++ class templates is not correct OR VS.NET is not standards compliant (I think its the former though).

I tried compiling a templated class, but I received the Linker errors stating that the compiler could not find any of the class methods. From my experience with templates, I believe you have two options:

1) Keep everything in the .h file.

2) Include the .cpp (I usually name them .inl) right after the class definition in the .cpp file. So you'll have in the .h file
#ifndef A_H#define A_Htemplate < typename T > class A{/* declarations here */ }; #include "A.inl"#endif


Other than that, very nice job. I should find this to be rather useful (It will save me from typing all those overloaded operator declarations).
I second the opinion to make it as a plugin for your favorite (or multiple) IDEs.

Its better than the "improved" class designer I found on CodeProject.com a month ago.
Thanks for the feedback.

Quote:Original post by wyrzy
(1) Support for inline files (either by adding a .inl or having all code in the .h file)


I'm not familiar with inline files ... I'll look into that.

Quote:
(2) I can specify a templated class, but I can not specify to inherit from a templated class. The syntax for inheriting from templated classes is slightly different than inheriting from non-templated classes.

Interesting ... never knew that ... I'll look into that as well.

Quote:
Also, I think the generated syntax for C++ class templates is not correct OR VS.NET is not standards compliant (I think its the former though).


Strange ... that's how my textbook does it. Guess I'll look into that as well...

Quote:
...
2) Include the .cpp (I usually name them .inl) right after the class definition in the .cpp file. So you'll have in the .h file
*** Source Snippet Removed ***


You lost me there ... include the cpp after the definition in the cpp? Could you elaborate?

I'll look into the plugin idea ... if it's not too complicated ... I didn't intend to spend too much time on this.

Thanks again.
The program will not run for me. I just get an error box saying "The application failed to initialize properly (0xc0000135). Click on OK to terminate the application." I tried downloading both the straight exe and the zip, both with the same result.

EDIT: Works fine on my other pc though
-Dan- Can't never could do anything | DansKingdom.com | Dynamic Particle System Framework for XNA

This topic is closed to new replies.

Advertisement