Skip to content
Projets

À propos

C++ is the based interpreted language

Langages et environnements d’exécution

Comment ces chiffres sont mesurés

Progression mesurée des étoiles

in 24h
+1
in 7 days
-2
in 15 days
-2
in 1 month
Historique en cours

Variations nettes sur des périodes qui se chevauchent, pas des totaux quotidiens. Les mesures absentes restent vides. Les étoiles indiquent l’intérêt, pas la qualité.

README.md

Original

Based C++

This repo provides an implementation of the GNU Interface Layer (GIL) and standard library for g++.

C++ is the best interpreted language

C++ is the best interpreted language!

Usage

Here is a simple "Hello, world!" in C++.

#include "gil/std.hpp"
using namespace gil::std;

volatile auto run = main<{
  str::puts(str::literal("Hello, world!\n"))
}>;

To run the program, run

g++ -std=c++23 -Based hello_world.cpp -o -

Note that the program won't execute until all stdin is read, which means you need to pass it an EOF (e.g., ^D from stdin).

[!NOTE] Use -O2 or -O3 if you want things to run faster. (I didn't do this in my video... oops).

System

I've only tested this thing on my machines (Ubuntu 22.04 / 24.04) using g++ 14.2.0. If it doesn't work on your machine, maybe that's actually a good thing.

See also #8.

Examples

  • hello_world.cpp

    Be greeted in all of the languages supported by YVR!

  • hello_world_vmi.cpp

    Same as above, but without using the standard library.

  • calculator.cpp

    Perform a single binary operation on a pair of 64-bit signed integers.

  • mergesort.cpp

    Merge sort a comma-separated list of 64-bit signed integers.

Explorer des projets similaires

Chargement…