C++

Asked • 09/23/19

*.h or *.hpp for your class definitions?

I've always used a `*.h` file for my class definitions, but after reading some boost library code, I realised they all use `*.hpp`. I've always had an aversion to that file extension, I think mainly because I'm not used to it. What are the advantages and disadvantages of using `*.hpp` over `*.h`?

1 Expert Answer

By:

Patrick B. answered • 10/05/19

Tutor
4.7 (31)

Math and computer tutor/teacher

Patrick B.

I have also used #include with resource files (*.res) and configuration files (*.ini)
Report

10/05/19

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.

OR

Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.