95 lines
1.4 KiB
YAML
95 lines
1.4 KiB
YAML
id: "c++"
|
|
aliases:
|
|
- "cpp"
|
|
- "g++"
|
|
- "clang++"
|
|
- "c++98"
|
|
- "c++03"
|
|
- "c++11"
|
|
- "c++14"
|
|
- "c++17"
|
|
- "c++20"
|
|
- "cpp98"
|
|
- "cpp03"
|
|
- "cpp11"
|
|
- "cpp14"
|
|
- "cpp17"
|
|
- "cpp20"
|
|
- "hpp"
|
|
- "cxx"
|
|
- "hxx"
|
|
name: "C++"
|
|
monacoLang: cpp
|
|
|
|
info:
|
|
impl: "LLVM"
|
|
version: "C++20"
|
|
year: 1985
|
|
desc: "General-purpose programming language created by Bjarne Stroustrup as an extension of the C programming language"
|
|
ext:
|
|
- C
|
|
- cc
|
|
- cpp
|
|
- cxx
|
|
- c++
|
|
- h
|
|
- hh
|
|
- hpp
|
|
- hxx
|
|
- h++
|
|
web:
|
|
wiki: "https://en.wikipedia.org/wiki/C%2B%2B"
|
|
impl: "https://llvm.org/"
|
|
source: "https://github.com/llvm/llvm-project"
|
|
category: general
|
|
mode: compiled
|
|
platform: []
|
|
syntax: c
|
|
typing: static
|
|
paradigm:
|
|
- functional
|
|
- imperative
|
|
- oo
|
|
usage: popular
|
|
|
|
install:
|
|
apt:
|
|
- clang
|
|
- clang-format
|
|
- clangd
|
|
|
|
main: "main.cpp"
|
|
template: |
|
|
#include <iostream>
|
|
|
|
int main() {
|
|
std::cout << "Hello, world!" << std::endl;
|
|
return 0;
|
|
}
|
|
|
|
compile: |
|
|
clang++ -std=c++17 -pedantic -Wall -Wextra main.cpp -o main
|
|
run: |
|
|
./main
|
|
|
|
format:
|
|
run: |
|
|
clang-format --assume-filename=format.cpp
|
|
input: |
|
|
#include <iostream>
|
|
|
|
int main()
|
|
{
|
|
std::cout << "Hello, world!" << std::endl;
|
|
return 0;
|
|
}
|
|
|
|
lsp:
|
|
setup: |
|
|
echo '-Wall -Wextra' | sed -E 's/\s+/\n/g' > compile_flags.txt
|
|
start: |
|
|
clangd
|
|
|
|
skip:
|
|
- lsp
|