6 ms·
Can anyone say what's the significance/unique value prop of this library when compared to things like boost, bde, etc.?
by polskibus 9y ago
Can anyone say what's the significance/unique value prop of this library when compared to things like boost, bde, etc.?
- packetslave 9y agoThe "Why Adopt Abseil" page does a pretty good job of laying out the value proposition: http://abseil.io/about/philosophy http://abseil.io/about/philosophy
- tudelo 9y agoThe text is so faint on this web page I hardly want to get through it...
- dom0 9y agoReader view to the rescue
- aaroninsf 9y agoIt's a sad commentary that this is now the de facto correct answer. Optics => default to _Designer view_. Superflat everything; no affordances. Pretty! Clean! Broken.
- evmar 9y agoI noticed that too, so I filed a bug in their repo: https://github.com/abseil/abseil.github.io/issues/46 https://github.com/abseil/abseil.github.io/issues/46
- hydrogen18 9y agoReadable text is overrated in 2017.
- andrewf 9y agoI'm having trouble reading your post, too!
- tudelo 9y agoI wonder why? HN has very readable text.
- fish_fan 9y agoTo take from javascript, this is a mix of underscore (utility) and, uhh, babel(?) for essentially polyfilling certain runtime features slated for future (hypothetical) approval.
- vvanders 9y agoCan't speak to Abseil but I won't let boost within 10,000 feet of any codebase I control. I value my compile times more than anything it provides.
- ubadair 9y agoBoost contains over 120 libraries and counting, with over 70 authors and maintainers. There are many parts of Boost that I will never use (e.g. most of the pre c++11 libs), but the pros of having it available when you need it far outweigh the cons. If a particular library is costing you more in compile time than it's worth in convenience, just rm -rf it from your Boost install -- better yet, write a script to prepend `static_assert(false, "this header is banned by decree of vvanders");` to the top of the banned headers. There's plenty in Boost to love -- don't let a few rotten apples spoil the bunch. Full disclosure: I'm a Boost developer
- vvanders 9y agoSo I should hack apart my install just to get to some basic level of compiler performance? Last time I looked at boost pulling in any header would pull in all of them, that's why it takes so long to compile. In this day with any modern C++0x11 compiler I don't really see the need for boost.
- Layuso 9y agoI value my developing times more than anything. Boost is one library which is developed and tested on almost every c++ target platform, providing us with stable, tested, and performing common utilities to speed up your developments and run anywhere. Reasons not to use boost: - My code is one monolithic spaghetti and I do not use unit tests. - I do not want to learn Boost. - I don't trust template hippies. Not using Boost is an irrational decision and you know it.
- 7197ghr918hf 9y agoA couple of my favorite types and functions in absl: - Span For when you want to take an array or a vector. - string_view Avoids string copies. Makes your program faster. Its creation was a reaction to situations like https://news.ycombinator.com/item?id=8704318 https://news.ycombinator.com/item?id=8704318. (It predates that revelation, but internally the plague of string copies has been known for some time.) - Mutex A better mutex with deadlock detection. - Substitute A string formatting function between 5 and 1000s of times faster than snprintf. Profile your code some time. If it's anything like mine, you might be surprised at how much this matters. - base::Time and base::Duration Excellent wall time utilities, similar to Go's wall clock time libraries.
- roel_v 9y ago"- Span For when you want to take an array or a vector." How's this different from taking a pair of iterators? "string_view" After having read all those articles about c++17's string_view, I still don't really get the real differences. OK, when parsing (i.e. using many substrings) it makes sense (but then you'd usually work with char* anyway); and maybe some people interact with C libraries that only take char* a lot (and in cases where they have to 'cross the boundary' often). So maybe in text-heavy applications (like I imagine C++ application for the web would be) it makes some sense, but I fail to understand why it's causing this much excitement. "Substitute" There are so many fast formatting libraries already - what does this one offer over those? Because it's generally a trade off between completeness/type safety on the one hand, and speed on the other. I use boost::format which is quite slow in benchmarks, but again I don't do much string processing. "base::Time and base::Duration" In what way are these different from boost::date_time and std::chrono? Here again the documentation (for Abseil) seem to be missing. I mean, I'm all for batteries-included libraries - but this just seems to be a few loosely-related classes slapped together and the only reason it's even on here is because it's from Google. There are dozens of similar libraries languishing on sourceforge and github. Compare it to e.g. POCO - this is not even in the same league.
- int_19h 9y ago> I fail to understand why it's causing this much excitement. C++ guys just like zero-overhead abstractions. The more we can get, the better. Passing std::string around has always been a sore point, and occasionally prompted misguided optimizations (like refcounting copy-on-write in g++).