Files
gt4carp/lepiter/7vxzpkk568l2l7dnam0zoyusu.bak
2022-04-17 22:43:27 +02:00

258 lines
7.1 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

{
"__schema" : "4.1",
"__type" : "page",
"children" : {
"__type" : "snippets",
"items" : [
{
"__type" : "textSnippet",
"children" : {
"__type" : "snippets",
"items" : [ ]
},
"createEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"createTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:22:53.22701+02:00"
}
},
"editEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"editTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:24:36.631484+02:00"
}
},
"uid" : {
"__type" : "uid",
"uidString" : "Dm0UJUGZDQCKn/UjBAU6hQ=="
},
"paragraphStyle" : {
"__type" : "textStyle"
},
"string" : "Before we build an IDE for Carp together, it might make sense to introduce you to Carp. Ive written about the language extensively on [my blog](https://veitheller.de), but Id like to take a stab at quickly introducing it here, for the purposes of this tutorial."
},
{
"__type" : "textSnippet",
"children" : {
"__type" : "snippets",
"items" : [ ]
},
"createEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"createTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:24:37.857895+02:00"
}
},
"editEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"editTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:25:41.467247+02:00"
}
},
"uid" : {
"__type" : "uid",
"uidString" : "x5dhK0GZDQCKodavBAU6hQ=="
},
"paragraphStyle" : {
"__type" : "textStyle"
},
"string" : "If the description whets your appetite, be sure to check it out [on Github](https://github.com) and join our community [on Gitter](https://gitter.im/carp-lang/carp)."
},
{
"__type" : "textSnippet",
"children" : {
"__type" : "snippets",
"items" : [ ]
},
"createEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"createTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:27:45.487766+02:00"
}
},
"editEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"editTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:39:56.823586+02:00"
}
},
"uid" : {
"__type" : "uid",
"uidString" : "i/93NkGZDQCKoyIwBAU6hQ=="
},
"paragraphStyle" : {
"__type" : "textStyle"
},
"string" : "##A short introduction"
},
{
"__type" : "textSnippet",
"children" : {
"__type" : "snippets",
"items" : [ ]
},
"createEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"createTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:28:00.226582+02:00"
}
},
"editEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"editTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:32:49.704279+02:00"
}
},
"uid" : {
"__type" : "uid",
"uidString" : "nlrWNkGZDQCKpcSZBAU6hQ=="
},
"paragraphStyle" : {
"__type" : "textStyle"
},
"string" : "As mentioned in the [[Introduction]], Carp is a **borrow-checked** language with **type inference** and **syntactic macros**. Outwardly, it takes the form of a Lisp akin to Clojure. The writing experience, however, is more like that of Rust or OCaml."
},
{
"__type" : "carpSnippet",
"children" : {
"__type" : "snippets",
"items" : [ ]
},
"createEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"createTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:32:53.393834+02:00"
}
},
"editEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"editTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:41:44.082741+02:00"
}
},
"uid" : {
"__type" : "uid",
"uidString" : "0En4SEGZDQCMIJywBAU6hQ=="
},
"code" : "; while global statements exist, Carp does most of its work inside modules\r(defmodule MyMod\r\r\t; we have\r\t; - macros,\r\t(defmacro mymacro [x] (eval 'x)) ; 'x is short for (quote x)\r\t\r\t; - dynamic functions and values (available at compile time), and\r\t(defdynamic dval 1)\r\t(defndynamic dfun [x] (fn [] (+ dval 1)))\r\t\r\t; - static functions and values\r\t(def val \"hi\")\r\t(defn fun [] @val) ; @val is a shorthand for (copy val)\r\t; NB: strings are references by default, they need to be copied\r\t\r\t; other syntactic features include\r\t(def array [1 2 3])\r\t(def map {1 2, 3 4}) ; commas are optional and treated like whitespace\r\t(def ref-1 &1) ; &1 is short for (ref 1), the inverse to copy\r\t\r\t(defdynamic quasiquoted `(1 2 dval %dval)) ; expands to '(1 2 dval 1)\r\t; quasiquoting is a bit of a complicated beast, and I wont delve too much\r\t; on it.\r\t\r\t; different number types have different suffixes\r\t(def an-int 1)\r\t(def a-long 1l)\r\t(def a-byte 1b)\r\t(def a-float 1.0f)\r\t(def a-double 1.0)\r)"
},
{
"__type" : "textSnippet",
"children" : {
"__type" : "snippets",
"items" : [ ]
},
"createEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"createTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:41:52.766276+02:00"
}
},
"editEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"editTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:42:04.686614+02:00"
}
},
"uid" : {
"__type" : "uid",
"uidString" : "CkwFaUGZDQCMI8MVBAU6hQ=="
},
"paragraphStyle" : {
"__type" : "textStyle"
},
"string" : "While Carp naturally has many more features, this should be enough to"
}
]
},
"createEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"createTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:22:51.219115+02:00"
}
},
"editEmail" : {
"__type" : "email",
"emailString" : "<unknown>"
},
"editTime" : {
"__type" : "time",
"time" : {
"__type" : "dateAndTime",
"dateAndTimeString" : "2022-04-17T22:22:51.219115+02:00"
}
},
"pageType" : {
"__type" : "namedPage",
"title" : "Interlude: An Introduction to Carp"
},
"uid" : {
"__type" : "uuid",
"uuid" : "6ed41325-4199-0d00-8a9e-533904053a85"
}
}