8 # nix run --impure --expr 'with import <nixpkgs> {}; jupyter-console.withSingleKernel cpp17-kernel'
11 # nix run --impure --expr 'with import <nixpkgs> {}; jupyter.override { definitions = { cpp17 = cpp17-kernel; }; }'
14 xeus-cling = callPackage ./xeus-cling.nix {};
19 if std == "c++11" then " 11"
20 else if std == "c++14" then " 14"
21 else if std == "c++17" then " 17"
22 else if std == "c++17" then " 17"
23 else if std == "c++2a" then " 2a"
24 else throw "Unexpected C++ std for cling: ${std}";
27 displayName = "C++" + versionSuffix;
29 "${xeus-cling}/bin/xcpp"
33 "-resource-dir" "${cling.unwrapped}"
34 "-L" "${cling.unwrapped}/lib"
35 "-l" "${cling.unwrapped}/lib/cling.so"
38 "-f" "{connection_file}"
42 url = "https://upload.wikimedia.org/wikipedia/commons/thumb/1/18/ISO_C%2B%2B_Logo.svg/32px-ISO_C%2B%2B_Logo.svg.png";
43 hash = "sha256-cr0TB8/j2mkcFhfCkz9F7ZANOuTlWA2OcWtDcXyOjHw=";
46 url = "https://upload.wikimedia.org/wikipedia/commons/thumb/1/18/ISO_C%2B%2B_Logo.svg/64px-ISO_C%2B%2B_Logo.svg.png";
47 hash = "sha256-nZtJ4bR7GmQttvqEJC9KejOxphrjjxT36L9yOIITFLk=";
54 cpp11-kernel = mkDefinition "c++11";
55 cpp14-kernel = mkDefinition "c++14";
56 cpp17-kernel = mkDefinition "c++17";
57 cpp2a-kernel = mkDefinition "c++2a";