summaryrefslogtreecommitdiff
path: root/README.EXT.jp
diff options
context:
space:
mode:
Diffstat (limited to 'README.EXT.jp')
-rw-r--r--README.EXT.jp14
1 files changed, 14 insertions, 0 deletions
diff --git a/README.EXT.jp b/README.EXT.jp
index ac4f3adca9..e8be946d68 100644
--- a/README.EXT.jp
+++ b/README.EXT.jp
@@ -180,6 +180,16 @@ Rubyが用意している関数を用いてください.
Cの文字列からRubyの文字列を生成する.この関数の機能は
rb_str_new(ptr, strlen(ptr))と同等である.
+ rb_tainted_str_new(char *ptr, int len)
+
+ 汚染マークが付加された新しいRubyの文字列を生成する.外部
+ からのデータに基づく文字列には汚染マークが付加されるべき
+ である.
+
+ rb_tainted_str_new2(char *ptr)
+
+ Cの文字列から汚染マークが付加されたRubyの文字列を生成する.
+
rb_str_cat(VALUE str, char *ptr, int len)
Rubyの文字列strにlenバイトの文字列ptrを追加する.
@@ -307,6 +317,10 @@ privateメソッドとは関数形式でしか呼び出すことの出来ないメソッ
void rb_define_global_function(char *name, VALUE (*func)(), int argc)
+メソッドの別名を定義するための関数は以下の通りです。
+
+ void rb_define_alias(VALUE module, const char* new, const char* old);
+
2.1.3 定数定義
拡張ライブラリが必要な定数はあらかじめ定義しておいた方が良い