- craft conf, Budapest (April 22-24) Many clojure and ICFP people
- code mesh, London (November 2-4)
- polyconf, POZnan (Poland) (July 2-4)
| ## DEFINITION ## | |
| # Compact version, with just a hint of meta-programming | |
| Item = ImmutableRecord.new(:foo, :bar) | |
| # Strict Equivalent, without meta-programming: | |
| class ItemBis < ImmutableRecord::Value | |
| def self.attributes | |
| [:foo, :bar] | |
| end |
| require 'active_support/core_ext' | |
| module T | |
| module T | |
| module T | |
| def self.zero; end | |
| end | |
| end | |
| end |
| (ns cljs.test.repl | |
| (:require [cljs.analyzer.api :as ana-api] | |
| [cljs.analyzer :as ana] | |
| [cljs.test])) | |
| (defmacro run-single-test [[quote var :as form]] | |
| (let [ns (or (some-> var namespace symbol) | |
| ana/*cljs-ns*)] | |
| `(cljs.test/run-block | |
| (concat |
| function dinghy-connect { | |
| # Make sure SSH agent is running | |
| ssh-add -K | |
| # Make sure dinghy is up and running | |
| dinghy create 2> /dev/null || echo "dinghy VM already created" | |
| dinghy up 2> /dev/null || echo "dinghy VM already running" | |
| # Check if SSH forwarding is already in place | |
| DINGHY_SSH_SOCK=$(dinghy ssh find -type f /tmp/ssh-*/agent.* 2> /dev/null || echo "missing") |
Write a script/program that reads a sequence of mathematical expressions from a file and prints the result of evaluating all expressions in the order they appear.
The file consists of a series of expressions, one per line.
Each line is in the format function <value>. ADD 5, for example, adds 5 to the current value.
The initial value when the program starts is 0. A file contains maximum ten rows.
The following functions shall be supported:
| {-# LANGUAGE Rank2Types #-} | |
| import Control.Lens hiding (element) | |
| import Data.Text as T (splitOn | |
| , concat | |
| , Text | |
| , pack | |
| , toTitle | |
| , toLower) | |
| twiceLens :: String -> Iso' Text (String, Text) |
| module Test | |
| import TestProvider | |
| %default total | |
| %language TypeProviders | |
| add : Int -> Int -> Int | |
| add x y = 0 | |
| %provide (result : String) with compileTest [ |
| require "continuation" | |
| class Hash | |
| alias_method :_original_lookup, :[] | |
| def [](key) | |
| _original_lookup(key).tap do | |
| callcc { |cc| $hash_cc = [cc]; nil }&.tap do |value_from_future| | |
| self[key] = value_from_future | |
| $hash_cc.pop.call(self) |