Compare Abseil with the Boost project

2,433 views
Skip to first unread message

Andrey Kraynov

unread,
Nov 7, 2017, 4:37:24 PM11/7/17
to Abseil.io
Hi!
What are the differences of Abseil library from the Boost library?
Sorry if that question was already answered.

Looks like Boost has many (if not all) concepts that Abseil is implementing.
Of cource, Boost is quite a huge project.
But with the BCP utility [1] it is possible to extract a lesser subpart.

One of the major differences that I can see, is that Abseil will use STL classes like string_view if it can and Boost will provide its own implementation.

Titus Winters

unread,
Nov 7, 2017, 10:43:46 PM11/7/17
to Andrey Kraynov, Abseil.io
At a high level - API differences abound.  While there are Mutex types in Abseil, Boost, and the standard, there are API differences in all cases.  Some of those are due to the design priorities, some are due to platform compatibility constraints. 

That gets at the most important answer to your question: what purpose do these libraries serve?  In the broad C++ community, Boost serves as a very important space for experimentation and innovation: many of the most important concepts in the standard came out of boost (shared_ptr, optional, etc), or were motivated as language-level solutions to problems that Boost demonstrated were legitimate (foreach => range-based loops). However, Boost provides little in the way of compatibility promises over time: a user of Boost has basically no promise that the APIs they rely upon will be stable from release to release.

Abseil, on the other hand, is all about compatibility over time.  If you are using it within the acceptable usage (https://abseil.io/about/compatibility) every update to Abseil will work for you ... or, if we have to make an API-incompatible change, we'll ship a tool that makes that change easy for you.  You should never be "stuck" on a previous version of Abseil because you can't afford to update, or something you depend upon is stuck - even a non-expert should be able to update all of their dependencies to a current version of Abseil with very limited guidance.  

If you want the newest, shiniest, most exciting / cutting edge APIs and dont' care about long term support, use Boost.
If you want compatibility for pre-compiled code over many years, use the standard.
If you can build from source and want performance and (maybe) more user-friendly APIs, use Abseil.  

Does that help?

--
You received this message because you are subscribed to the Google Groups "Abseil.io" group.
To unsubscribe from this group and stop receiving emails from it, send an email to abseil-io+...@googlegroups.com.
To post to this group, send email to abse...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/abseil-io/63f6d760-19ab-4eb1-935e-741b1202dd6f%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Andrey Kraynov

unread,
Nov 8, 2017, 1:07:59 AM11/8/17
to Abseil.io
That definitely makes sense.
Thank you for the great and detailed answer.
Reply all
Reply to author
Forward
0 new messages