æ æ¥è¨ã°ããã§ã¢ã¬ãªã®ã§ãAndreiã®ã»ãã·ã§ã³ã§ãç¹ã«é¢ç½ãã£ããã®ãç´¹ä»ãããã C++0xã§ã¯ãtupleããµãã¼ãããã¦ãããä»»æã®é·ãã®tupleã«å¯¾ãã¦ããé¢æ°ãé©ç¨ãããå ´åã©ãããã ããï¼ ã¾ããä»»æã®é·ãã®tupleã¯ãã³ãã¬ã¼ãå¼æ°ã«Variadic Templatesã®Template Parameter Packã渡ããã¨ã«ãªãã 以ä¸ãã³ã¼ãã¤ã¡ã¼ã¸ã ã template <class F, class... Ts> typename std::function<F>::result_type apply(F& fun, std::tuple<Ts...>& args) { return fun(args...); } æ®å¿µãªããããã¯ã³ã³ãã¤ã«ã§ããªããåé¡ã¯ãfunã®å¼ã³åºãã®å¼æ°ã§ãããargsã¯ãåãªãã¯ã©ã¹ãã³ãã¬ã¼ãtupleã¸ã®åç §ã§ããããã®ã¯ã©
{{#tags}}- {{label}}
{{/tags}}