Is C++ an open-source project? Which community developes it? [closed] - c++

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
The community reviewed whether to reopen this question 1 year ago and left it closed:
Not suitable for this site
Improve this question
I have some questions about C++:
Is C++ an open-source project like Linux, Qt, ... or not?
Which community maintains C++ and develops new versions?
If it is open-source where can one access the source code for C++
implementations?

C++ itself is only a description what the language should be,
without a definite implementation.
Anyone can make his own implementations (compiler etc, runtime library, ...)
and call it C++ if it fits to the description.
http://www.open-std.org/jtc1/sc22/wg21/
And if a implementation is open source depends on the creator.
Examples of implementation (parts):
GCC/G++, libc/libc++, clang (++ too), Visual studio and MS´ runtime...

C++ is developed by an ISO standard committee. There's also a C++ foundation that runs a web site you might want to read.
C++ itself is a language, not a specific implementation, so there's no source code available for the standard/language itself.
Some C++ implementations are open source (e.g., Gnu and Clang).

C++ is a code standard defined by the International Organization of Standardization (ISO). There are many different implementations of the language, but they all tend to conform to C++11. Unlike Linux or Qt, C++ is just a standard, and to use any code written in the language you'll need a compiler. The major compilers (list from Wikipedia) are LLVM Clang, GCC, Microsoft Visual C++, and the Intel C++ Compiler.
C++ revisions are dealt with by ISO, and are influenced primarily by the maintainers of the above four implementations.
Clang and GCC are both open-source, I'm sure if you poke around you can find other conforming compilers but those are the two most used.

C++ is an ISO standard. There are many implementation of compilers (and linkers). GCC is an open source project of many compilers one of which is the C++ compiler, g++:
http://gcc.gnu.org/projects/cxx0x.html

Related

Regular expression implementation that can be use for gcc4.8 [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 2 years ago.
Improve this question
Regular expressions will not work on gcc4.8 based on what I found out.
During cross compile I encountered run time errors with regards to regular expressions.
Do you know other ways how can i work with regex at gcc4.8?
I am thinking of creating my own but I wander if there is already available that can be use.
GCC 4.8 is really old (and no more maintained in 2020).
Consider updating it -in October 2020- to GCC 10 (whose source code you could compile) and read documentation about invoking GCC and using GDB. I suggest compiling with g++ -Wall -Wextra -g using a recent GCC.
Read at least the C++11 standard n3337 and a good C++ programming book and more about the #include <regex> standard header.
On Linux and POSIX systems, you could use regex(3). The source code is available, since open source (in e.g. the GNU libc or the musl-libc) and with permission you can adapt it to your working context.
You could also use Qt or POCO. Both have some regular expressions facilities and are open source. So you can study their source code implementation of regular expressions and their relation to push down automata. Read also about recursive descent parsers and consider using parser generators (if allowed) such as GNU bison, flex, or ANTLR. If performance is a major concern, consider using (with permission) code generating libraries like libgccjit, asmjit, GNU lightning, tinycc.
Of course, read the Dragon book. It explains the basic concepts for regular expressions. Read also recent papers to ACM SIGPLAN conferences.
If your management requires specifically GCC 4.8 (I would consider changing jobs with such a stupid requirement - since cross compiling GCC 10 is quite easy, and GCC improved a lot in five years), you should at least ask permission to compile some existing regular expression open source libraries (you'll find many of them on github or gitlab), or in boost.
Consider of course asking permission to use a recent Clang compiler (you could compile it from its source code, since it is open source), the Clang static analyzer, and perhaps Frama-C++, and to read this draft report. See also the CHARIOT and DECODER European projects.
PS. Cross-compiling GCC 10 takes one or two days (if you are a newbie). Writing your regular expression library could take you several weeks.

Do you need c++ 17 for learning c++ from 2020? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 2 years ago.
Improve this question
I'm using Window 7 OS, I'm Learning C++ for Competitive Programming. I downloaded a version of CodeBlocks but it does not have C++17 (it only has C++98 and C++0x). Is C++17 really important for Learning C++ [preferably for Competitive Programming] or can I carry with my pre-existing CodeBlocks Version? Also, if C++17 is Preferred can you please provide the source to Download C++17 IDE (Codeblocks or Visual Studio). A link would even be more welcomed.
C++17 does not give you access to a new language, it is just an update to an existing language. Most of the competitive programming sites will have c++14 or c++17 running on their servers, so it is preferably good to have one. If you want a pre installed IDE then you can look at the latest version of Visual Studio (probably 2019). Or if you just want a compiler then you can look at MinGW.
Download Visual Studio : https://visualstudio.microsoft.com/vs/
Download MinGW : https://osdn.net/projects/mingw/downloads/68260/mingw-get-setup.exe/
Regarding MinGW, it is just a compiler, if you want to use it, then you have to install something like Visual Studio Code, Sublime Text, Atom, etc and then set it up yourself or look at some tutorials on YouTube. Lastly, if you have any other doubts, comment on this answer and I will be pleased to look into the matter.
The version of CodeBlocks you have installed is not the latest. The latest official release (20.03) provides the bundle MinGW compiler version 8.1.0 which supports C++14 and C++17, I seem to remember.
I advise you to install the IDE (CodeBlocks) and the compiler separately.
By installing Msys2 you have the possibility to always update mingw to the latest version (the latest gcc (10.2) offers support for C++20, as well as C++17, 14 and 11).

What is the most complete and reliable open source C++11 IDE for Windows? [closed]

Closed. This question is opinion-based. It is not currently accepting answers.
Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.
Closed 9 years ago.
Improve this question
I don't intend this to be an opinion question and I am deliberately avoiding the word "best" for that reason. To frame my question differently;
Is there a fully C++11 compatible Open Source and free (as in free speech, beer and lunch, not as in Express, Lite, Demo, etc.) IDE that provides stable syntax and error highlighting a la IntelliSense, that works out of the box with C++11, or at least with a minimal, easy to follow amount of work?
I am asking this question because I really like the VS2012 environment but have become frustrated with the lackluster degree of C++11 compatibility, and my license is due to expire anyway.
Have you tried the "Visual C++ Compiler November 2012 CTP" update? It adds support for several features (most notably variadic templates) to VC11. The library is not there, and this compiler update is not considered production-ready, but I've found it to be great for working on my projects and using C++11 code till the final product comes out.
Also, I have used Qt Creator (quite independent from the Qt toolkit) for GCC-based C++11 development and it's a great IDE.
First: it's not (mainly) the IDE that needs the C++11 Support, but the compiler. That being said - here are some options:
it is possible to integrate clang into VS2012 (check here: https://github.com/ishani/ClangVSx)
You can use any IDE that supports MINGW as compiler (Windows-GCC-Port) e.g. Eclipse CDT, QT Creator, Code::Blocks, DevCpp
You can use any IDE that supports Clang as compiler (e.g. Code::Blocks)
According to http://www.codelite.org/LiteEditor/ClangIntegration, you can configure codelite to use Clang for code completion vs. gcc. So depending on the IDE, the compiler might provide things like code completion.

What the main reason to use stlport library in the code?

I saw someone use stlport in visual c++, but I think standard c++ library is included with visual c++ already? what's the advantage to use stlport? is stlport free?
Most likely either the code was written before visual c++ had a full implementation (for example in VC6) or the code is cross platform and the author wanted to make sure the same library was there on each platform. (That's not so much of an issue recently but even 2 or 3 years ago there were much more substantial differences from the standard in each implementation)

How can I compile under C++11 standard in Ubuntu? [closed]

Closed. This question is off-topic. It is not currently accepting answers.
Want to improve this question? Update the question so it's on-topic for Stack Overflow.
Closed 11 years ago.
Improve this question
How may I compile a C++ program under the C++11 standard in Ubuntu 11.04 with the most up-to-date compiler, at best using compiler from the distribution, i.e., pre-built package.
GCC 4.6 provides most of the C++11 features. One has only to add the flag -std=c++0x and can use range based for loops, strong enums, UTF strings, etc. For the list of features available in a given version of GCC one can check on http://gcc.gnu.org/projects/cxx0x.html.
Update in 2017: It seem GCC 7 and higher has full C++ 2011 compliance. The rest of the answer below was written in the GCC 4.7 era, and was correct when written in 2011.
Strictly speaking, I can not offer you any 100% C++ 2011 compliant open source compiler, because there aren't any that are 100% there yet.
It looks like you should stay with GCC for now, and GCC 4.6 binaries are included in recent Ubuntu distributions. C++ 2011 is incomplete in GCC 4.6 but contains a lot of 2011 stuff, more than Clang+llvm. It's more than 90% C++ 2011 feature complete. GCC 4.7 contains yet more stuff, but I don't see gcc-4.7 binary packages in Ubuntu 11.x yet, but you can check over here for another way to get gcc 4.7 binaries on ubuntu, or try AskUbuntu, a stackexchange powered site for ubuntu.
According to this page Clang+llvm does not yet offer full C++ 2011 standards compliance, either, and I haven't done the exact math but I see a lot more "No" entries on Clang, versus Gcc.