What are the alternatives to the standard C++ library and boost with a clear implementation? [closed]

£可爱£侵袭症+ 提交于 2019-12-11 09:37:31

问题


I don't have particular problems with the standard library, the only real issue is that the C++ library is used interfacing the code with a bunch of headers and the real implementation heavily depends on what my application will find on the target machine in terms of libraries.

So I was looking for libraries with containers, algorithms and iteraators, maybe open source, with a clear implementation, so far i have only found this 2:

  • boost library
  • QT library

But none of this is a real C++ standard library, with this I mean that QT is mainly a GUI library that also offers containers and other good stuff, boost is simpy huge and all the C++ std-like components are just a really small part of this library, also this library it's not really trivial to port to a new target because the build system have a non-standard toolchain and it uses its own build solution ( bjam ).

In the end with both boost and QT i don't get an easy solution or a workable solution that can replace the C++ library as i wish it would be.

So far the best project that i have found is the Apache C++ Standard Library that was just right but this project is dead.

Someone can suggest a library that just replaces the standard library and it's open-source with a permissive license ?


回答1:


the real implementation heavily depends on what my application will find on the target machine in terms of libraries

The real implementation basically depends on your compiler, not the machine you're running your programs on.

Different compilers may come with different implementations, however I believe this is no reason to replace such an extensive and well-thought out library with something home-made. That's the very reason you're unlikely to find a replacement library that is this good.




回答2:


Noone seems to understand what you want to achieve by switching to an alternative library, which is why you don't get any answers.

STL library is universally availbale on anything from toasters to supercomputers. It is also aggresively optimised to deliver the highest possible performance on the target platform.

Now, let me clarify some of your points.

P1. "real implementation heavily depends on what my application will find on the target machine in terms of libraries"

Wrong, C++ standard library is implemented on top of C standard library, both of them are supplied along with any descent compiler. Both can use system calls to do some low level stuff, like open files, create threads etc. That's it, no other dependencies, guaranteed by standard.



来源:https://stackoverflow.com/questions/13085275/what-are-the-alternatives-to-the-standard-c-library-and-boost-with-a-clear-imp

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!