@yuya_takeyama
Domain Specific    Languages    (Martin Fowler)
[	 	 "foo",	 	 "bar",	 	 "hoge"	 =>	 "piyo"]
array(3)	 {	 	 [0]=>	 	 string(3)	 "foo"	 	 [1]=>	 	 string(3)	 "bar"	 	 ["hoge"]=>	 	 string(4)	 "piyo"}
public	 $id	 =	 array(	 	 type	 	 	 	 =>	 int,	 	 primary	 =>	 true,	 	 	 serial	 	 =>	 true);public	 $name	 =	 array(	 	 ...
public	 $id	 =	 [	 	 int,	 	 primary	 =>	 true,	 	 	 serial	 	 =>	 true];public	 $name	 =	 [	 	 string,	 	 required	 =>	 t...
[begin,	 	 [define,	 	 	 	 fib,	 	 	 	 [lambda,	 	 	 	 	 	 [x],	 	 	 	 	 	 [if,	 	 	 	 	 	 	 	 [<,	 :x,	 2],	 	 	 	 	 	 	 ...
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Making DSL with []
Upcoming SlideShare
Loading in …5
×

Making DSL with []

3,510 views

Published on

  • Be the first to comment

Making DSL with []

  1. 1. @yuya_takeyama
  2. 2. Domain Specific Languages (Martin Fowler)
  3. 3. [ "foo", "bar", "hoge" => "piyo"]
  4. 4. array(3) { [0]=> string(3) "foo" [1]=> string(3) "bar" ["hoge"]=> string(4) "piyo"}
  5. 5. public $id = array( type => int, primary => true, serial => true);public $name = array( type =>string, required => true, unique => true);public $birthday = array( type => date);
  6. 6. public $id = [ int, primary => true, serial => true];public $name = [ string, required => true, unique => true];public $birthday = [date];
  7. 7. [begin, [define, fib, [lambda, [x], [if, [<, :x, 2], :x, [+, [fib, [-, :x, 2]], [fib, [-, :x, 1]]]]]], [print, fib(10) = ], [println, [fib, 10]]] => fib(10) = 55

×