cancel
Showing results for 
Search instead for 
Did you mean: 

When building a C++ STM32 Project, how do I associate the .hpp file extension with combined header and source templates and Class files?

DWild.1
Associate II

In my regular C++ work, I use the BOOST library, and I've taken to using their .hpp style that combines header declarations and source definitions in one file for most of my C++ work. I try to not use separate .h and .cpp files any more, whether it is a template or a normal C++ class.

The way it is now, the system whines when I try to define a class with only one source or header file.

I want to add this to my global workspace properties, not do it for every project I create.

This discussion is locked. Please start a new topic to ask your question.
2 REPLIES 2
TDK
Super User

> The way it is now, the system whines when I try to define a class with only one source or header file.

What do you mean?

I use hpp files all the time and haven't had issues. Create it as a header file. Add its location as an include directory path.

If you feel a post has answered your question, please click "Accept as Solution".

I figured out that I can do that, yes, by making the file by hand or combining the two and renaming.

I was trying to get it to use the Eclipse CDT create New Class feature to give me all my stub functions in the CubeIDE.

Announcement

We’re moving the ST Community to a new platform to give you a better and more reliable community experience.