2014-08-05から1日間の記事一覧
// CoffeeScript簡易コンパイラ // CoffeeCompile.jse // カレントをスクリプトのあるパスにする var fso = new ActiveXObject("Scripting.FileSystemObject") var WShell = new ActiveXObject("WScript.Shell") WShell.CurrentDirectory = fso.GetFile(WScr…
s=""; s+="f=->\n"; s+=" alert[ 'Hello. #{language}.'\n"; try { compiled = CoffeeScript.compile(s); console.log(compiled); } catch(e) { console.log(e.location.first_line); console.log(e.location.first_column); console.log(e.message); }