Skip to content

Instantly share code, notes, and snippets.

@zakki
zakki / jetzt-solid.js
Created October 28, 2015 08:59
jetzt + TinySegmenter
/*! jetzt 2015-10-28
* https://ds300.github.io/jetzt/
* Copyright (c) 2015 David Sheldrick and contributors; Licensed Apache 2.0 */
// TinySegmenter 0.1 -- Super compact Japanese tokenizer in Javascript
// (c) 2008 Taku Kudo <taku@chasen.org>
// TinySegmenter is freely distributable under the terms of a new BSD licence.
// For details, see http://chasen.org/~taku/software/TinySegmenter/LICENCE.txt
module.exports = function(grunt) {
// require("time-grunt")(grunt);
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
opt: {
client: {
"tsMain": "src",
"tsMainLib": "typings",
//http://codemonkeyism.com/how-to-improve-programming-with-interfaces/
case class Person(n:String) { def name():String = n }
type Nameable = { def name():String }
def printName(n:Nameable) { println(n.name) }
printName(new Person("Codemonkey"))
#include <stdio.h>
#include <stdlib.h>
#include <vector>
#include <chrono>
#include <thread>
#include <mutex>
#include <iostream>
using namespace std;
let f a b _ =
a + b
let f2 a =
f a 1
let () =
print_int (f 1 2 3);
print_newline ();
From 51f165b05a354ea047aca4436c191c2008d5058d Mon Sep 17 00:00:00 2001
From: MATSUZAKI Kensuke <zakki@peppermint.jp>
Date: Fri, 12 Jun 2015 17:39:11 +0900
Subject: [PATCH] Fix drawing
---
Makefile | 2 +-
graph.ml | 11 +++++++----
2 files changed, 8 insertions(+), 5 deletions(-)
hsp3dish/emscripten/hgiox.cpp | 12 ++++++++++++
hsp3dish/hgio.h | 2 ++
hsp3dish/hsp3gr_dish.cpp | 5 +++++
3 files changed, 19 insertions(+)
diff --git a/hsp3dish/emscripten/hgiox.cpp b/hsp3dish/emscripten/hgiox.cpp
index 428f5d1..d22b885 100644
--- a/hsp3dish/emscripten/hgiox.cpp
+++ b/hsp3dish/emscripten/hgiox.cpp
@@ -662,6 +662,18 @@ int hgio_getHeight( void )
(defvar *howm-truname-cache* nil)
(defun howm-file-truename (filename)
(or
(cdr (assoc filename *howm-truname-cache*))
(let ((f (file-truename (expand-file-name filename))))
(add-to-list '*howm-truname-cache* (cons filename f))
f)))
(defun howm-normalize-file-name (filename)
open Domain
let rec f i n =
if n mod 1000 = 0 then
Printf.printf "%d %d\n" i n;
f i (n + 1)
let () =
for i = 0 to 3 do
Printf.printf "%d\n" i;
import javafx.application.Application;
import javafx.scene.AmbientLight;
import javafx.scene.Group;
import javafx.scene.PerspectiveCamera;
import javafx.scene.PointLight;
import javafx.scene.Scene;
import javafx.scene.paint.Color;
import javafx.scene.paint.PhongMaterial;
import javafx.scene.shape.Box;
import javafx.scene.shape.CullFace;