é¢æ°åããã°ã©ãã³ã°è¨èªã触ã£ããã¨ããªãã®ã§ãããé¢æ°çãã©ããã¯ç¥ããªããããã¡ãã¡ function ã¨ã return ã¨ãæ¸ãã®ã¯é¢åãããã¨æã£ãã®ã¨ãé¢æ°ã®å¤å½¢ãã beyond.js ãboost::bind ã«å½±é¿ãåãã¦ãé¢æ°ã®å¤å½¢ãè¡ãã©ã¤ãã©ãªãä½ã£ãã ã¾ãã¯å¼æ°ã®æç¸ãåã³å ¥ãæ¿ãããé¢æ°ã®å¤å½¢ãåã³ boost::bind ã«ãªãã£ã¦å¾ã å ¥åãããå¼æ°ã _n ã§ãããããã¨ã«ããã function concat(a, b) { return "" + a + b; } concat.bind(_1, "a")("b"); // "ba" concat.bind("a", _1)("b"); // "ab" concat.bind(_2, _1)("a", "b"); // "ba" concat.bind(_1, _1)("a"); // "aa" 次ã«é¢
{{#tags}}- {{label}}
{{/tags}}