/
niceSOFT
/
swig
Обзор
Документация
Войти
/
niceSOFT
/
swig
Код
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
Lib/ruby/std_functors.i
29 строк
767 B
William S Fulton
Convert Doxygen comment markers to plain C comments in SWIG source
09 июн 2026, 00:16
09 июн 2026, 00:16
d224682
Код
Авторство
О чём код?
/* * @file std_functors.i * @date Sun May 6 00:44:33 2007 * * @brief This file provides unary and binary functors for STL * containers, that will invoke a Ruby proc or method to do * their operation. * * You can use them in a swig file like: * * %include <std_set.i> * %include <std_functors.i> * * %template< IntSet > std::set< int, swig::BinaryPredicate<int> >; * * * which will then allow calling them from Ruby either like: * * # order of set is defined by C++ default * a = IntSet.new * * # sort order defined by Ruby proc * b = IntSet.new( proc { |a,b| a > b } ) * */ %include <rubystdfunctors.swg> %fragment("StdFunctors");