英語版
このページの英語版を見る
dmd.backend.dlist
C リンクリスト型とのインターフェイス".
リストは、ポインタや整数の単一リンクリストを扱う関数の完全なパッケージである。
ポインタや整数のリストを扱う関数の完全なパッケージである。
特徴
- memパッケージを使う。
- ループバック・テストがある。
- リスト内の各項目は複数の前任者を持つことができる。 異なるリストが共通の末尾を「共有」できる。
Authors:
License:
ソース backend/dlist.d
- nothrow @nogc @safe list_t
list_next(list_tlist); - Returns:リストの次のエントリへのポインタ。
- nothrow @nogc @trusted inout(void)*
list_ptr(inout list_tlist); - Returns:リストエントリからの ptr。
- nothrow @nogc @safe int
list_data(list_tlist); - Returns:整数項目をリスト項目から取り出す。
- nothrow @nogc @safe void
list_prependdata(list_t*plist, intd); - 整数アイテムをリストにプリペンドする。
- nothrow @nogc @trusted void
list_free(list_t*plist, list_free_fpfreeptr); - リストを解放する。Parameters:
list_t* plist解放するリストへのポインタ list_free_fp freeptrデータ・ポインタの解放関数へのポインタ。 (ない場合はFPNULLを使用) 出力 *plistがNULLである
- nothrow @nogc @trusted void*
list_subtract(list_t*plist, void*ptr); - plistが指すリストからptrを削除する。
出力 *plistは新しいリストの先頭に更新される。
Returns:plistがNULLの場合はNULL そうでなければ ptr - nothrow @nogc @safe void*
list_pop(list_t*plist); - plistが指すリストの最初の要素を削除する。Returns:最初の要素、*plist が NULL ならば NULL
- nothrow @nogc @trusted list_t
list_append(list_t*plist, void*ptr); - ptrを*plistに追加する。Returns:作成されたリスト項目へのポインタ。 メモリ不足の場合はnull
- nothrow @nogc @trusted list_t
list_prepend(list_t*plist, void*ptr); - ptrを*plistにプリペンドする。Returns:作成されたリスト項目へのポインタ(リストの開始点でもある)。 メモリ不足の場合はnull
- nothrow @nogc @safe int
list_nitems(list_tlist); - リスト内の項目数をカウントアップして返す。Returns:
リストの項目数
- nothrow @nogc @safe list_t
list_nth(list_tlist, intn); - Returns:リストの n 番目の項目。
- nothrow @nogc @safe int
list_equal(list_tlist1, list_tlist2); - 2つのリストを比較する。Returns:同じptrであれば1を返し、そうでなければ0を返す。
- nothrow @nogc @trusted list_t
list_inlist(list_tlist, void*ptr); - リスト内のptrを検索する。Returns:見つかればそのリストエントリを返し、そうでなければnullを返す。
- nothrow @nogc @trusted void
list_apply(list_t*plist, void function(void*) nothrow @nogcfp); - リストの各メンバーに関数fpを適用する。
- nothrow @nogc @safe list_t
list_reverse(list_tl); - リストをその場で反転する。
- struct
ListRange; - リストの範囲。
Copyright © 1999-2025 by the D Language Foundation
DEEPL APIにより翻訳、ところどころ修正。
このページの最新版(英語)
このページの原文(英語)
翻訳時のdmdのバージョン: 2.108.0
サイト全体のドキュメントのdmdのバージョン: 2.109.1
最新のdmdのバージョン: 2.111.0 ダウンロード
翻訳日付:
HTML生成日時:
編集者: dokutoku