summaryrefslogtreecommitdiffstats
path: root/clang/test/Driver/unknown-std.c
Commit message (Collapse)AuthorAgeFilesLines
* Add a new language mode for C2x; enable [[attribute]] support by default in C2x.Aaron Ballman2019-05-141-0/+2
| | | | llvm-svn: 360667
* Add language standard aliases for -std=c18, -std=gnu18, and -std=iso9899:2018.Aaron Ballman2018-10-181-2/+2
| | | | | | As described in D40225, the C17 standard was balloted and approved in 2017, but the ISO publication process delayed the actual publication until 2018. WG14 considers the release to be C17 and describes it as such, but users can still be confused by the publication year which is why -std=c18 adds value. These aliases map to c17 and are all supported by GCC 8.x with the same behavior. Note that the value of __STDC_VERSION__ remains at 201710L. llvm-svn: 344749
* Correct line endings that got mixed up in r320089; NFC.Aaron Ballman2017-12-071-22/+22
| | | | llvm-svn: 320113
* Add new language mode flags for C17.Aaron Ballman2017-12-071-20/+22
| | | | | | This adds -std=c17, -std=gnu17, and -std=iso9899:2017 as language mode flags for C17 and updates the value of __STDC_VERSION__ to the value based on the C17 FDIS. Given that this ballot cannot succeed until 2018, it is expected that we (and GCC) will add c18 flags as aliases once the ballot passes. llvm-svn: 320089
* Improve diagnostics for bad -std= flag.Richard Smith2017-04-271-15/+4
| | | | | | | | | | | Don't list deprecated -std= values (c++0x etc). Only produce one line of output per standard, even if we know it by multiple names. In passing, add missing -std=gnu++03 alias (supported by GCC), and add new spelling '-std=cl1.0' for OpenCL 1.0 for consistency with the other values, with the same meaning as the preexisting '-std=cl'. llvm-svn: 301507
* Don't accept -std= values that would switch us to a different source language.Richard Smith2017-04-261-6/+3
| | | | | | | | | | | | | | | | | | | | | We already prohibited this in most cases (in r130710), but had some bugs in our enforcement of this rule. Specifically, this prevents the following combinations: * -x c -std=clN.M, which would previously effectively act as if -x cl were used, despite the input being a C source file. (-x cl -std=cNN continues to be disallowed.) * -x c++ -std=cuda, which would previously select C++98 + CUDA, despite that not being a C++ standard. (-x cuda -std=c++NN is still permitted, and selects CUDA with the given C++ standard as its base language. -x cuda -std=cuda is still supported with the meaning of CUDA + C++98.) * -x renderscript -std=c++NN, which would previously form a hybrid "C++ with RenderScript extensions" language. We could support such a thing, but shouldn't do so by accident. llvm-svn: 301497
* [Driver] Report available language standards on user errorRichard Smith2017-02-141-0/+34
In case user did not provide valid standard name for -std option, available values (with short description) will be reported. Patch by Paweł Żukowski! llvm-svn: 295113
OpenPOWER on IntegriCloud