Chapter 23 The str library: 正規表現と文字列処理

The Objective Caml system release 3.10

str ライブラリは高度な文字列処理関数を提供します(一部の関数は正規表現に基づきます)。これらは、普通 awk, perl や sed のようなスクリプト言語で行われるような ファイル処理をサポートすることを意図しています。

str ライブラリを使うプログラムは以下のようにリンクする必要があります:

ocamlc other options str.cma other files
ocamlopt other options str.cmxa other files

インタラクティブモードで str ライブラリを使うには以下のようにします:

ocamlmktop -o mytop str.cma
./mytop

あるいは(あなたのプラットフォームが C ライブラリのダイナミックリンクをサポートする場合には)、ocaml を起動して #load "str.cma";; と入力してください。

  • Module Str: regular expressions and string processing

新規 編集 添付