node.js ãã¤ãã£ã¦ããã¨ãã«ããµã¨ C è¨èªãæ¸ããããªã£ãããããã¨ã¯ããã¾ããã? åã¯ããã¾ããã ããããæã«ã¯ãnode-tcc ãã¤ããã¨ããã§ãããnode-tcc 㯠TinyCC( http://bellard.org/tcc/ ) ã® node.js ãã¤ã³ãã£ã³ã°ã§ããããã¤ããã¨ä»¥ä¸ã®ããã«ãç°¡åã« C è¨èªãå®è¡ãããã¨ãã§ãã¾ãã var TCC = require('tcc'), var tcc = new TCC(); tcc.compile_string('int main() { return 4649; }'); var ret = tcc.run(); // => 4649 ããããããã ãã§ã¯ãC è¨èªãã¤ããããªãã¦ããã¨ã¯ãããªãã§ããããåºåããmain é¢æ°ã®è¿ãå¤ããããã¾ãããããã ãã㧠node-ffi ã®åºçªã§ãã以ä¸ã®
{{#tags}}- {{label}}
{{/tags}}