Boost logo

Boost Users :

Subject: Re: [Boost-users] Why is BOOST_OS_WINDOWS defined on Linux
From: Chris Glover (c.d.glover_at_[hidden])
Date: 2018-05-04 11:54:41


On Fri, 4 May 2018 at 01:57 David Demelier <markand_at_[hidden]> wrote:

>
> Just curious, is there some coding convention in boost? I just realized
> predef is the only one component that I use which use .h header suffix
> instead of .hpp.
>
>
There are some rough guidelines here:

https://www.boost.org/development/requirements.html

The menu to the right, under Requirements and Guidelines contains a few
related links.

The relevant bit to your question is this;

"Files intended to be processed by a C++ compiler as part of a translation
unit should have a three-letter filename extension ending in "pp". Other
files should not use extensions ending in "pp". This convention makes it
easy to identify all of the C++ source in Boost."

So, the .h files don't require a C++ compiler and could be used in C.

-- chris



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net