英和訓練

著作権は原文に属します

(WIP) Problem Solving and Clojure 1.9 with Rich Hickey

Joy Clark: Hello, everyone, and welcome to a new conversation about software engineering. こんにちはみなさん。ソフトウェア工学についての今回の会話にようこそ。This is Joy Clark, and today on the CaSE Podcast I'm going to be talking to Rich Hickey about Clojure, and all of the reasons why Clojure is the way it is. 私はJoy Clarkです。今日のCaSE Podcastでは、Clojureと、その開発の方針について、Rich Hickeyと話します。Thank you, Rich, for joining me today. Rich、参加してくれてありがとう。

続きを読む

Reference - Namespaces 名前空間

Namespaces are mappings from simple (unqualified) symbols to Vars and/or Classes. 名前空間は、シンプルな(修飾されていない)シンボルからVarおよび/またはClassへのマップである。Vars can be interned in a namespace, using def or any of its variants, in which case they have a simple symbol for a name and a reference to their containing namespace, and the namespace maps that symbol to the same var. Varらは、defやそれに類するものを用いることである名前空間にinternされうる。その場合には、Varは名前としてシンプルなシンボルを持ち、自身を含む名前空間を参照する。そしてその名前空間は、そのシンボルからそのvarへとマップする。A namespace can also contain mappings from symbols to vars interned in other namespaces by using refer or use, or from symbols to Class objects by using import. referないしuseが使われた場合には、名前空間はシンボルから、他の名前空間にinternされたvarへもマップする。また、importされた際には、名前空間はシンボルからClassへマップする。 Note that namespaces are first-class, they can be enumerated etc. 名前空間は第一級であるから、列挙等されうる。Namespaces are also dynamic, they can be created, removed and modified at runtime, at the Repl etc. 名前空間は動的でもある。よってRepl等によって実行時に、作成、削除、変更されうる。

続きを読む

Reference - Macros マクロ

Clojure has a programmatic macro system which allows the compiler to be extended by user code. Clojureにはプログラムによるマクロシステムがあり、それによって、ユーザのコードによりコンパイラを拡張できる。Macros can be used to define syntactic constructs which would require primitives or built-in support in other languages. 他の言語であれば組み込みの基本要素などとして実現するほかないような構文的要素を、マクロでならば定義できる。 Many core constructs of Clojure are not, in fact, primitives, but are normal macros. 一見Clojureの基本要素に見えるものの多くは実際には通常のマクロとして実装されている。

続きを読む

(WIP) Guides - spec Guide

Getting started 始め方

The spec library specifies the structure of data, validates or destructures it, and can generate data based on the spec. specライブラリを用いると、データの構造のスペックを書くことができる。また、データを検証したり分割することができ、記述したスペックに従ってデータを自動生成することもできる。

続きを読む