Repository navigation
Expand file tree
/
Copy pathstructures.po
More file actions
1481 lines (1262 loc) · 61.5 KB
/
Copy pathstructures.po
File metadata and controls
1481 lines (1262 loc) · 61.5 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
# SOME DESCRIPTIVE TITLE.
# Copyright (C) 2001 Python Software Foundation
# This file is distributed under the same license as the Python package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
# Translators:
# python-doc bot, 2025
# Inada Naoki <songofacandy@gmail.com>, 2026
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: Python 3.15\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2026-10-29 19:20+0000\n"
"PO-Revision-Date: 2025-09-16 00:00+0000\n"
"Last-Translator: Inada Naoki <songofacandy@gmail.com>, 2026\n"
"Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/"
"ja/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: ja\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#: ../../c-api/structures.rst:6
msgid "Common Object Structures"
msgstr "共通のオブジェクト構造体 (common object structure)"
msgid ""
"There are a large number of structures which are used in the definition of "
"object types for Python. This section describes these structures and how "
"they are used."
msgstr ""
"Python のオブジェクト型の定義には、多数の構造体が使われます。\n"
"この節では、それらの構造体と使い方を説明します。"
msgid "Base object types and macros"
msgstr "基本のオブジェクト型とマクロ"
msgid ""
"All Python objects ultimately share a small number of fields at the "
"beginning of the object's representation in memory. These are represented "
"by the :c:type:`PyObject` and :c:type:`PyVarObject` types, which are "
"defined, in turn, by the expansions of some macros also used, whether "
"directly or indirectly, in the definition of all other Python objects. "
"Additional macros can be found under :ref:`reference counting "
"<countingrefs>`."
msgstr ""
"すべての Python オブジェクトは、メモリ上の表現の先頭に少数の共通フィールドを"
"持ちます。\n"
"これらを表すのが :c:type:`PyObject` 型と :c:type:`PyVarObject` 型です。\n"
"これらの型はマクロの展開によって定義され、そのマクロは他のすべての Python オ"
"ブジェクトの定義でも直接的または間接的に使われます。\n"
"その他のマクロについては :ref:`参照カウント <countingrefs>` を参照してくださ"
"い。"
#: ../../c-api/structures.rst:26
msgid ""
"All object types are extensions of this type. This is a type which contains "
"the information Python needs to treat a pointer to an object as an object. "
"In a normal \"release\" build, it contains only the object's reference count "
"and a pointer to the corresponding type object. Nothing is actually declared "
"to be a :c:type:`PyObject`, but every pointer to a Python object can be cast "
"to a :c:expr:`PyObject*`."
msgstr ""
msgid ""
"The members must not be accessed directly; instead use macros such "
"as :c:macro:`Py_REFCNT` and :c:macro:`Py_TYPE`."
msgstr ""
"メンバーに直接アクセスしてはいけません。\n"
"代わりに :c:macro:`Py_REFCNT` や :c:macro:`Py_TYPE` などのマクロを使ってくだ"
"さい。"
msgid ""
"In the :ref:`Stable ABI <stable-abi>` for Free-Threaded Builds (``abi3t``), "
"this struct is opaque; its size and layout may change between Python "
"versions. In Stable ABI for non-free-threaded builds (``abi3``), "
"the :c:member:`!ob_refcnt` and :c:member:`!ob_type` fields are available, "
"but using them directly is discouraged."
msgstr ""
"フリースレッドビルド用の :ref:`Stable ABI <stable-abi>` (``abi3t``) では、こ"
"の構造体は不透明で、サイズやレイアウトは Python のバージョン間で変わる可能性"
"があります。\n"
"フリースレッドでないビルド用の Stable ABI (``abi3``) では :c:member:`!"
"ob_refcnt` フィールドと :c:member:`!ob_type` フィールドを利用できますが、直接"
"使うことは推奨されません。"
msgid ""
"The object's reference count, as returned by :c:macro:`Py_REFCNT`. Do not "
"use this field directly; instead use functions and macros such as :c:macro:`!"
"Py_REFCNT`, :c:func:`Py_INCREF` and :c:func:`Py_DecRef`."
msgstr ""
":c:macro:`Py_REFCNT` が返す、オブジェクトの参照カウントです。\n"
"このフィールドを直接使わず、代わりに :c:macro:`!"
"Py_REFCNT`、:c:func:`Py_INCREF`、:c:func:`Py_DecRef` などの関数やマクロを使っ"
"てください。"
msgid ""
"The field type may be different from ``Py_ssize_t``, depending on build "
"configuration and platform."
msgstr ""
"ビルド構成やプラットフォームによっては、フィールドの型は ``Py_ssize_t`` と異"
"なる場合があります。"
msgid ""
"The object's type. Do not use this field directly; use :c:macro:`Py_TYPE` "
"and :c:func:`Py_SET_TYPE` instead."
msgstr ""
"オブジェクトの型です。\n"
"このフィールドを直接使わず、代わりに :c:macro:`Py_TYPE` "
"と :c:func:`Py_SET_TYPE` を使ってください。"
msgid ""
"A :ref:`per-object lock <per-object-locks>`, present only in the :term:`free-"
"threaded <free threading>` build (when :c:macro:`Py_GIL_DISABLED` is "
"defined)."
msgstr ""
":term:`フリースレッド <free threading>` ビルド (:c:macro:`Py_GIL_DISABLED` が"
"定義されている場合) にだけ存在する、:ref:`オブジェクトごとのロック <per-"
"object-locks>` です。"
msgid ""
"This field is **reserved for use by the critical section API** "
"(:c:macro:`Py_BEGIN_CRITICAL_SECTION` / :c:macro:`Py_END_CRITICAL_SECTION`). "
"Do **not** lock it directly with ``PyMutex_Lock``; doing so can cause "
"deadlocks. If you need your own lock, add a separate :c:type:`PyMutex` "
"field to your object struct."
msgstr ""
"このフィールドは **クリティカルセクション API 専用** です "
"(:c:macro:`Py_BEGIN_CRITICAL_SECTION` / :c:macro:`Py_END_CRITICAL_SECTION`)。\n"
"``PyMutex_Lock`` で直接ロックしては **いけません**。\n"
"デッドロックを引き起こす可能性があります。\n"
"独自のロックが必要なら、オブジェクトの構造体に別の :c:type:`PyMutex` フィール"
"ドを追加してください。"
msgid ""
"An extension of :c:type:`PyObject` that adds "
"the :c:member:`~PyVarObject.ob_size` field. This is intended for objects "
"that have some notion of *length*."
msgstr ""
":c:type:`PyObject` に :c:member:`~PyVarObject.ob_size` フィールドを追加した型"
"です。\n"
"何らかの *長さ* の概念を持つオブジェクトを対象としています。"
msgid ""
"As with :c:type:`!PyObject`, the members must not be accessed directly; "
"instead use macros such as :c:macro:`Py_SIZE`, :c:macro:`Py_REFCNT` "
"and :c:macro:`Py_TYPE`."
msgstr ""
":c:type:`!PyObject` と同様に、メンバーに直接アクセスしてはいけません。\n"
"代わりに :c:macro:`Py_SIZE`、:c:macro:`Py_REFCNT`、:c:macro:`Py_TYPE` などの"
"マクロを使ってください。"
msgid ""
"In the :ref:`Stable ABI <stable-abi>` for Free-Threaded Builds (``abi3t``), "
"this struct is opaque; its size and layout may change between Python "
"versions. In Stable ABI for non-free-threaded builds (``abi3``), "
"the :c:member:`!ob_base` and :c:member:`!ob_size` fields are available, but "
"using them directly is discouraged."
msgstr ""
"フリースレッドビルド用の :ref:`Stable ABI <stable-abi>` (``abi3t``) では、こ"
"の構造体は不透明で、サイズやレイアウトは Python のバージョン間で変わる可能性"
"があります。\n"
"フリースレッドでないビルド用の Stable ABI (``abi3``) では :c:member:`!"
"ob_base` フィールドと :c:member:`!ob_size` フィールドを利用できますが、直接使"
"うことは推奨されません。"
msgid ""
"Common object header. Typically, this field is not accessed directly; "
"instead :c:type:`!PyVarObject` can be cast to :c:type:`PyObject`."
msgstr ""
"共通のオブジェクトヘッダーです。\n"
"通常、このフィールドには直接アクセスせず、代わりに :c:type:`!PyVarObject` "
"を :c:type:`PyObject` にキャストします。"
msgid ""
"A size field, whose contents should be considered an object's internal "
"implementation detail."
msgstr ""
"サイズを保持するフィールドです。\n"
"その内容はオブジェクト内部の実装詳細として扱うべきです。"
msgid "Do not use this field directly; use :c:macro:`Py_SIZE` instead."
msgstr ""
"このフィールドを直接使わず、代わりに :c:macro:`Py_SIZE` を使ってください。"
msgid ""
"Object creation functions such as :c:func:`PyObject_NewVar` will generally "
"set this field to the requested size (number of items). After creation, "
"arbitrary values can be stored in :c:member:`!ob_size` "
"using :c:macro:`Py_SET_SIZE`."
msgstr ""
":c:func:`PyObject_NewVar` などのオブジェクト作成関数は、通常、このフィールド"
"に要求されたサイズ (要素数) を設定します。\n"
"作成後は :c:macro:`Py_SET_SIZE` を使って :c:member:`!ob_size` に任意の値を格"
"納できます。"
msgid ""
"To get an object's publicly exposed length, as returned by the Python "
"function :py:func:`len`, use :c:func:`PyObject_Length` instead."
msgstr ""
"Python の :py:func:`len` 関数が返す、公開されたオブジェクトの長さを取得するに"
"は、代わりに :c:func:`PyObject_Length` を使ってください。"
#: ../../c-api/structures.rst:114
msgid ""
"This is a macro used when declaring new types which represent objects "
"without a varying length. The PyObject_HEAD macro expands to::"
msgstr ""
"可変な長さを持たないオブジェクトを表現する新しい型を宣言するときに使うマクロ"
"です。\n"
"PyObject_HEAD マクロは次のように展開されます::"
msgid "PyObject ob_base;"
msgstr "PyObject ob_base;"
#: ../../c-api/structures.rst:119
msgid "See documentation of :c:type:`PyObject` above."
msgstr "上にある :c:type:`PyObject` のドキュメントを参照してください。"
#: ../../c-api/structures.rst:124
msgid ""
"This is a macro used when declaring new types which represent objects with a "
"length that varies from instance to instance. The PyObject_VAR_HEAD macro "
"expands to::"
msgstr ""
"インスタンスごとに異なる長さを持つオブジェクトを表現する新しい型を宣言すると"
"きに使うマクロです。\n"
"PyObject_VAR_HEAD マクロは次のように展開されます::"
msgid "PyVarObject ob_base;"
msgstr "PyVarObject ob_base;"
#: ../../c-api/structures.rst:130
msgid "See documentation of :c:type:`PyVarObject` above."
msgstr "上にある :c:type:`PyVarObject` のドキュメントを参照してください。"
msgid ""
"The base class of all other objects, the same as :class:`object` in Python."
msgstr ""
"他のすべてのオブジェクトの基底クラスで、Python の :class:`object` と同じで"
"す。"
msgid ""
"Test if the *x* object is the *y* object, the same as ``x is y`` in Python."
msgstr ""
"オブジェクト *x* がオブジェクト *y* かどうかを調べます。\n"
"Python の ``x is y`` と同じです。"
msgid ""
"Test if an object is the ``None`` singleton, the same as ``x is None`` in "
"Python."
msgstr ""
"オブジェクトが ``None`` シングルトンかどうかを調べます。\n"
"Python の ``x is None`` と同じです。"
msgid ""
"Test if an object is the ``True`` singleton, the same as ``x is True`` in "
"Python."
msgstr ""
"オブジェクトが ``True`` シングルトンかどうかを調べます。\n"
"Python の ``x is True`` と同じです。"
msgid ""
"Test if an object is the ``False`` singleton, the same as ``x is False`` in "
"Python."
msgstr ""
"オブジェクトが ``False`` シングルトンかどうかを調べます。\n"
"Python の ``x is False`` と同じです。"
msgid "Get the type of the Python object *o*."
msgstr "Python オブジェクト *o* の型を取得します。"
msgid ""
"The returned reference is :term:`borrowed <borrowed reference>` from *o*. Do "
"not release it with :c:func:`Py_DECREF` or similar."
msgstr ""
"返される参照は *o* からの :term:`借用参照 <borrowed reference>` です。\n"
":c:func:`Py_DECREF` などで解放しないでください。"
msgid ""
":c:func:`Py_TYPE()` is changed to an inline static function. The parameter "
"type is no longer :c:expr:`const PyObject*`."
msgstr ""
":c:func:`Py_TYPE()` が static なインライン関数になりました。\n"
"引数の型は :c:expr:`const PyObject*` ではなくなりました。"
msgid ""
"Return non-zero if the object *o* type is *type*. Return zero otherwise. "
"Equivalent to: ``Py_TYPE(o) == type``."
msgstr ""
"オブジェクト *o* の型が *type* ならゼロ以外、それ以外ならゼロを返します。\n"
"``Py_TYPE(o) == type`` と同等です。"
msgid ""
"Set the type of object *o* to *type*, without any checking or reference "
"counting."
msgstr ""
"オブジェクト *o* の型を *type* に設定します。\n"
"検証も参照カウントの操作も行いません。"
msgid ""
"This is a very low-level operation. Consider instead setting the Python "
"attribute :attr:`~object.__class__` using :c:func:`PyObject_SetAttrString` "
"or similar."
msgstr ""
"これは非常に低レベルの操作です。\n"
"代わりに :c:func:`PyObject_SetAttrString` などで Python の属"
"性 :attr:`~object.__class__` を設定することを検討してください。"
msgid ""
"Note that assigning an incompatible type can lead to undefined behavior."
msgstr "互換性のない型を代入すると、未定義の動作を引き起こす可能性があります。"
msgid ""
"If *type* is a :ref:`heap type <heap-types>`, the caller must create a new "
"reference to it. Similarly, if the old type of *o* is a heap type, the "
"caller must release a reference to that type."
msgstr ""
"*type* が :ref:`ヒープ型 <heap-types>` である場合、呼び出し側はその型への新し"
"い参照を作成する必要があります。\n"
"同様に、*o* の以前の型がヒープ型である場合は、その型への参照を解放する必要が"
"あります。"
msgid "Get the :c:member:`~PyVarObject.ob_size` field of *o*."
msgstr "*o* の :c:member:`~PyVarObject.ob_size` フィールドを取得します。"
msgid ""
":c:func:`Py_SIZE()` is changed to an inline static function. The parameter "
"type is no longer :c:expr:`const PyVarObject*`."
msgstr ""
":c:func:`Py_SIZE()` が static なインライン関数になりました。\n"
"引数の型は :c:expr:`const PyVarObject*` ではなくなりました。"
msgid "Set the :c:member:`~PyVarObject.ob_size` field of *o* to *size*."
msgstr ""
"*o* の :c:member:`~PyVarObject.ob_size` フィールドを *size* に設定します。"
#: ../../c-api/structures.rst:226
msgid ""
"This is a macro which expands to initialization values for a "
"new :c:type:`PyObject` type. This macro expands to::"
msgstr ""
"新しい :c:type:`PyObject` 型のための初期値に展開するマクロです。このマクロは"
"次のように展開されます。 ::"
#: ../../c-api/structures.rst:229
msgid ""
"_PyObject_EXTRA_INIT\n"
"1, type,"
msgstr ""
msgid ""
"This is a macro which expands to initialization values for a "
"new :c:type:`PyVarObject` type, including "
"the :c:member:`~PyVarObject.ob_size` field. This macro expands to::"
msgstr ""
":c:member:`~PyVarObject.ob_size` フィールドを含む、新し"
"い :c:type:`PyVarObject` 型の初期値に展開されるマクロです。\n"
"次のように展開されます。 ::"
#: ../../c-api/structures.rst:239
msgid ""
"_PyObject_EXTRA_INIT\n"
"1, type, size,"
msgstr ""
msgid "Implementing functions and methods"
msgstr "関数とメソッドの実装"
msgid ""
"Type of the functions used to implement most Python callables in C. "
"Functions of this type take two :c:expr:`PyObject*` parameters and return "
"one such value. If the return value is ``NULL``, an exception shall have "
"been set. If not ``NULL``, the return value is interpreted as the return "
"value of the function as exposed in Python. The function must return a new "
"reference."
msgstr ""
"Python の呼び出し可能オブジェクトの多くを C で実装するための関数の型です。\n"
"この型の関数は 2 つの :c:expr:`PyObject*` 引数を受け取り、同じ型の値を返しま"
"す。\n"
"戻り値が ``NULL`` の場合、例外が設定されていなければなりません。\n"
"``NULL`` でない場合は、Python に公開された関数の戻り値として扱われます。\n"
"この関数は新しい参照を返さなければなりません。"
#: ../../c-api/structures.rst:255
msgid "The function signature is::"
msgstr "関数のシグネチャは次のとおりです ::"
msgid ""
"PyObject *PyCFunction(PyObject *self,\n"
" PyObject *args);"
msgstr ""
"PyObject *PyCFunction(PyObject *self,\n"
" PyObject *args);"
msgid ""
"Type of the functions used to implement Python callables in C with "
"signature :ref:`METH_VARARGS | METH_KEYWORDS <METH_VARARGS-METH_KEYWORDS>`. "
"The function signature is::"
msgstr ""
":ref:`METH_VARARGS | METH_KEYWORDS <METH_VARARGS-METH_KEYWORDS>` のシグネチャ"
"を持つ Python の呼び出し可能オブジェクトを C で実装するための関数の型です。\n"
"シグネチャは次のとおりです。 ::"
msgid ""
"PyObject *PyCFunctionWithKeywords(PyObject *self,\n"
" PyObject *args,\n"
" PyObject *kwargs);"
msgstr ""
"PyObject *PyCFunctionWithKeywords(PyObject *self,\n"
" PyObject *args,\n"
" PyObject *kwargs);"
msgid ""
"Type of the functions used to implement Python callables in C with "
"signature :c:macro:`METH_FASTCALL`. The function signature is::"
msgstr ""
":c:macro:`METH_FASTCALL` のシグネチャを持つ Python の呼び出し可能オブジェクト"
"を C で実装するための関数の型です。\n"
"シグネチャは次のとおりです。 ::"
msgid ""
"PyObject *PyCFunctionFast(PyObject *self,\n"
" PyObject *const *args,\n"
" Py_ssize_t nargs);"
msgstr ""
"PyObject *PyCFunctionFast(PyObject *self,\n"
" PyObject *const *args,\n"
" Py_ssize_t nargs);"
msgid ""
"Type of the functions used to implement Python callables in C with "
"signature :ref:`METH_FASTCALL | METH_KEYWORDS <METH_FASTCALL-"
"METH_KEYWORDS>`. The function signature is::"
msgstr ""
":ref:`METH_FASTCALL | METH_KEYWORDS <METH_FASTCALL-METH_KEYWORDS>` のシグネ"
"チャを持つ Python の呼び出し可能オブジェクトを C で実装するための関数の型で"
"す。\n"
"シグネチャは次のとおりです。 ::"
msgid ""
"PyObject *PyCFunctionFastWithKeywords(PyObject *self,\n"
" PyObject *const *args,\n"
" Py_ssize_t nargs,\n"
" PyObject *kwnames);"
msgstr ""
"PyObject *PyCFunctionFastWithKeywords(PyObject *self,\n"
" PyObject *const *args,\n"
" Py_ssize_t nargs,\n"
" PyObject *kwnames);"
msgid ""
"Type of the functions used to implement Python callables in C with "
"signature :ref:`METH_METHOD | METH_FASTCALL | METH_KEYWORDS <METH_METHOD-"
"METH_FASTCALL-METH_KEYWORDS>`. The function signature is::"
msgstr ""
":ref:`METH_METHOD | METH_FASTCALL | METH_KEYWORDS <METH_METHOD-METH_FASTCALL-"
"METH_KEYWORDS>` のシグネチャを持つ Python の呼び出し可能オブジェクトを C で実"
"装するための関数の型です。\n"
"シグネチャは次のとおりです。 ::"
msgid ""
"PyObject *PyCMethod(PyObject *self,\n"
" PyTypeObject *defining_class,\n"
" PyObject *const *args,\n"
" Py_ssize_t nargs,\n"
" PyObject *kwnames)"
msgstr ""
"PyObject *PyCMethod(PyObject *self,\n"
" PyTypeObject *defining_class,\n"
" PyObject *const *args,\n"
" Py_ssize_t nargs,\n"
" PyObject *kwnames)"
#: ../../c-api/structures.rst:309
msgid ""
"Structure used to describe a method of an extension type. This structure "
"has four fields:"
msgstr ""
"拡張型のメソッドを記述する際に用いる構造体です。この構造体には 4 つのフィール"
"ドがあります:"
msgid "Name of the method."
msgstr "メソッドの名前。"
msgid "A ``NULL`` *ml_name* marks the end of a :c:type:`!PyMethodDef` array."
msgstr ""
"*ml_name* が ``NULL`` のエントリーは、:c:type:`!PyMethodDef` 配列の終端を示し"
"ます。"
msgid "Pointer to the C implementation."
msgstr "C での実装へのポインタ。"
msgid "Flags bits indicating how the call should be constructed."
msgstr "呼び出しの構成方法を示すフラグビット。"
msgid "Points to the contents of the docstring."
msgstr "ドキュメント文字列の内容へのポインタ。"
msgid ""
"The :c:member:`~PyMethodDef.ml_meth` is a C function pointer. The functions "
"may be of different types, but they always return :c:expr:`PyObject*`. If "
"the function is not of the :c:type:`PyCFunction`, the compiler will require "
"a cast in the method table. Even though :c:type:`PyCFunction` defines the "
"first parameter as :c:expr:`PyObject*`, it is common that the method "
"implementation uses the specific C type of the *self* object."
msgstr ""
":c:member:`~PyMethodDef.ml_meth` は C の関数ポインタです。\n"
"関数の型はさまざまですが、戻り値は常に :c:expr:`PyObject*` です。\n"
"関数が :c:type:`PyCFunction` 型でない場合、メソッドテーブル内でのキャストがコ"
"ンパイラから要求されます。\n"
":c:type:`PyCFunction` では第 1 引数を :c:expr:`PyObject*` と定義しています"
"が、メソッドの実装では *self* オブジェクト固有の C 型を使うのが一般的です。"
msgid ""
"The :c:member:`~PyMethodDef.ml_flags` field is a bitfield which can include "
"the following flags. The individual flags indicate either a calling "
"convention or a binding convention."
msgstr ""
":c:member:`~PyMethodDef.ml_flags` フィールドは、次のフラグを含められるビット"
"フィールドです。\n"
"各フラグは呼び出し規約または束縛の規約を示します。"
msgid "There are these calling conventions:"
msgstr "次の呼び出し規約があります。"
#: ../../c-api/structures.rst:347
msgid ""
"This is the typical calling convention, where the methods have the "
"type :c:type:`PyCFunction`. The function expects two :c:expr:`PyObject*` "
"values. The first one is the *self* object for methods; for module "
"functions, it is the module object. The second parameter (often called "
"*args*) is a tuple object representing all arguments. This parameter is "
"typically processed using :c:func:`PyArg_ParseTuple` "
"or :c:func:`PyArg_UnpackTuple`."
msgstr ""
":c:type:`PyCFunction` 型のメソッドで典型的に使われる呼び出し規約です。関数"
"は :c:expr:`PyObject*` 型の引数値を二つ要求します。最初の引数はメソッドの "
"*self* オブジェクトです; モジュール関数の場合、これはモジュールオブジェクトで"
"す。第二のパラメタ (よく *args* と呼ばれます) は、全ての引数を表現するタプル"
"オブジェクトです。パラメタは通常、 :c:func:`PyArg_ParseTuple` "
"や :c:func:`PyArg_UnpackTuple` で処理されます。"
msgid ""
"Can only be used in certain combinations with other "
"flags: :ref:`METH_VARARGS | METH_KEYWORDS <METH_VARARGS-"
"METH_KEYWORDS>`, :ref:`METH_FASTCALL | METH_KEYWORDS <METH_FASTCALL-"
"METH_KEYWORDS>` and :ref:`METH_METHOD | METH_FASTCALL | METH_KEYWORDS "
"<METH_METHOD-METH_FASTCALL-METH_KEYWORDS>`."
msgstr ""
"他のフラグとの特定の組み合わせでのみ使えます。\n"
"使えるのは :ref:`METH_VARARGS | METH_KEYWORDS <METH_VARARGS-"
"METH_KEYWORDS>`、:ref:`METH_FASTCALL | METH_KEYWORDS <METH_FASTCALL-"
"METH_KEYWORDS>`、:ref:`METH_METHOD | METH_FASTCALL | METH_KEYWORDS "
"<METH_METHOD-METH_FASTCALL-METH_KEYWORDS>` です。"
msgid ":c:expr:`METH_VARARGS | METH_KEYWORDS`"
msgstr ":c:expr:`METH_VARARGS | METH_KEYWORDS`"
msgid ""
"Methods with these flags must be of type :c:type:`PyCFunctionWithKeywords`. "
"The function expects three parameters: *self*, *args*, *kwargs* where "
"*kwargs* is a dictionary of all the keyword arguments or possibly ``NULL`` "
"if there are no keyword arguments. The parameters are typically processed "
"using :c:func:`PyArg_ParseTupleAndKeywords`."
msgstr ""
"これらのフラグを持つメソッドは :c:type:`PyCFunctionWithKeywords` 型でなければ"
"なりません。\n"
"この関数は *self*、*args*、*kwargs* の 3 引数を受け取ります。\n"
"*kwargs* はすべてのキーワード引数を含む辞書で、キーワード引数がなければ "
"``NULL`` の場合もあります。\n"
"通常は :c:func:`PyArg_ParseTupleAndKeywords` で引数を処理します。"
msgid ""
"Fast calling convention supporting only positional arguments. The methods "
"have the type :c:type:`PyCFunctionFast`. The first parameter is *self*, the "
"second parameter is a C array of :c:expr:`PyObject*` values indicating the "
"arguments and the third parameter is the number of arguments (the length of "
"the array)."
msgstr ""
"位置引数のみをサポートする高速な呼び出し規約です。\n"
"メソッドは :c:type:`PyCFunctionFast` 型です。\n"
"第 1 引数は *self*、第 2 引数は引数を表す :c:expr:`PyObject*` 値の C 配列、"
"第 3 引数は引数の個数 (配列の長さ) です。"
msgid "``METH_FASTCALL`` is now part of the :ref:`stable ABI <stable-abi>`."
msgstr ""
"``METH_FASTCALL`` が :ref:`Stable ABI <stable-abi>` の一部になりました。"
msgid ":c:expr:`METH_FASTCALL | METH_KEYWORDS`"
msgstr ":c:expr:`METH_FASTCALL | METH_KEYWORDS`"
msgid ""
"Extension of :c:macro:`METH_FASTCALL` supporting also keyword arguments, "
"with methods of type :c:type:`PyCFunctionFastWithKeywords`. Keyword "
"arguments are passed the same way as in the :ref:`vectorcall protocol "
"<vectorcall>`: there is an additional fourth :c:expr:`PyObject*` parameter "
"which is a tuple representing the names of the keyword arguments (which are "
"guaranteed to be strings) or possibly ``NULL`` if there are no keywords. "
"The values of the keyword arguments are stored in the *args* array, after "
"the positional arguments."
msgstr ""
":c:macro:`METH_FASTCALL` を拡張してキーワード引数もサポートするもので、メソッ"
"ドは :c:type:`PyCFunctionFastWithKeywords` 型です。\n"
"キーワード引数は :ref:`vectorcall プロトコル <vectorcall>` と同じ方法で渡され"
"ます。\n"
":c:expr:`PyObject*` 型の第 4 引数が追加され、キーワード引数の名前 (文字列であ"
"ることが保証されます) のタプルを渡します。\n"
"キーワード引数がなければ ``NULL`` の場合もあります。\n"
"キーワード引数の値は *args* 配列の位置引数の後に格納されます。"
msgid ""
"Can only be used in the combination with other flags: :ref:`METH_METHOD | "
"METH_FASTCALL | METH_KEYWORDS <METH_METHOD-METH_FASTCALL-METH_KEYWORDS>`."
msgstr ""
"他のフラグとの組み合わせ :ref:`METH_METHOD | METH_FASTCALL | METH_KEYWORDS "
"<METH_METHOD-METH_FASTCALL-METH_KEYWORDS>` でのみ使えます。"
msgid ":c:expr:`METH_METHOD | METH_FASTCALL | METH_KEYWORDS`"
msgstr ":c:expr:`METH_METHOD | METH_FASTCALL | METH_KEYWORDS`"
msgid ""
"Extension of :ref:`METH_FASTCALL | METH_KEYWORDS <METH_FASTCALL-"
"METH_KEYWORDS>` supporting the *defining class*, that is, the class that "
"contains the method in question. The defining class might be a superclass of "
"``Py_TYPE(self)``."
msgstr ""
":ref:`METH_FASTCALL | METH_KEYWORDS <METH_FASTCALL-METH_KEYWORDS>` を拡張し、"
"*定義元のクラス*、つまりそのメソッドを含むクラスを扱えるようにしたもので"
"す。\n"
"定義元のクラスは ``Py_TYPE(self)`` の基底クラスである場合もあります。"
msgid ""
"The method needs to be of type :c:type:`PyCMethod`, the same as for "
"``METH_FASTCALL | METH_KEYWORDS`` with ``defining_class`` argument added "
"after ``self``."
msgstr ""
"メソッドは :c:type:`PyCMethod` 型でなければなりません。\n"
"これは ``METH_FASTCALL | METH_KEYWORDS`` と同じですが、``self`` の後に "
"``defining_class`` 引数が追加されています。"
msgid ""
"Methods without parameters don't need to check whether arguments are given "
"if they are listed with the :c:macro:`METH_NOARGS` flag. They need to be of "
"type :c:type:`PyCFunction`. The first parameter is typically named *self* "
"and will hold a reference to the module or object instance. In all cases "
"the second parameter will be ``NULL``."
msgstr ""
"引数を取らないメソッドに :c:macro:`METH_NOARGS` フラグを指定すると、引数が渡"
"されたかどうかをメソッド内で確認する必要がなくなります。\n"
"このメソッドは :c:type:`PyCFunction` 型でなければなりません。\n"
"第 1 引数は通常 *self* という名前で、モジュールまたはオブジェクトのインスタン"
"スへの参照を保持します。\n"
"第 2 引数は常に ``NULL`` です。"
msgid ""
"The function must have 2 parameters. Since the second parameter is "
"unused, :c:macro:`Py_UNUSED` can be used to prevent a compiler warning."
msgstr ""
"関数には 2 つの引数が必要です。\n"
"第 2 引数は使わないので、:c:macro:`Py_UNUSED` でコンパイラの警告を抑制できま"
"す。"
msgid ""
"Methods with a single object argument can be listed with "
"the :c:macro:`METH_O` flag, instead of invoking :c:func:`PyArg_ParseTuple` "
"with a ``\"O\"`` argument. They have the type :c:type:`PyCFunction`, with "
"the *self* parameter, and a :c:expr:`PyObject*` parameter representing the "
"single argument."
msgstr ""
"オブジェクトを 1 つ引数に取るメソッドには、``\"O\"`` を指定し"
"て :c:func:`PyArg_ParseTuple` を呼び出す代わりに、:c:macro:`METH_O` フラグを"
"指定できます。\n"
"メソッドは :c:type:`PyCFunction` 型で、*self* 引数と、唯一の引数を表"
"す :c:expr:`PyObject*` 引数を受け取ります。"
msgid ""
"These two constants are not used to indicate the calling convention but the "
"binding when used with methods of classes. These may not be used for "
"functions defined for modules. At most one of these flags may be set for "
"any given method."
msgstr ""
"次の 2 つの定数は呼び出し規約ではなく、クラスのメソッドでの束縛を指定しま"
"す。\n"
"モジュールで定義する関数には使えません。\n"
"1 つのメソッドに設定できるのは、どちらか 1 つだけです。"
msgid ""
"The method will be passed the type object as the first parameter rather than "
"an instance of the type. This is used to create *class methods*, similar to "
"what is created when using the :deco:`classmethod` built-in decorator."
msgstr ""
"メソッドの第 1 引数には、型のインスタンスの代わりに型オブジェクトが渡されま"
"す。\n"
"組み込みデコレータ :deco:`classmethod` で作成されるものと同様の *クラスメソッ"
"ド* を作成するために使います。"
msgid ""
"The method will be passed ``NULL`` as the first parameter rather than an "
"instance of the type. This is used to create *static methods*, similar to "
"what is created when using the :deco:`staticmethod` built-in decorator."
msgstr ""
"メソッドの第 1 引数には、型のインスタンスの代わりに ``NULL`` が渡されます。\n"
"組み込みデコレータ :deco:`staticmethod` で作成されるものと同様の *静的メソッ"
"ド* を作成するために使います。"
#: ../../c-api/structures.rst:469
msgid ""
"One other constant controls whether a method is loaded in place of another "
"definition with the same method name."
msgstr ""
"もう一つの定数は、あるメソッドを同名の別のメソッド定義と置き換えるかどうかを"
"制御します。"
msgid ""
"The method will be loaded in place of existing definitions. Without "
"*METH_COEXIST*, the default is to skip repeated definitions. Since slot "
"wrappers are loaded before the method table, the existence of a "
"*sq_contains* slot, for example, would generate a wrapped method "
"named :meth:`~object.__contains__` and preclude the loading of a "
"corresponding PyCFunction with the same name. With the flag defined, the "
"PyCFunction will be loaded in place of the wrapper object and will co-exist "
"with the slot. This is helpful because calls to PyCFunctions are optimized "
"more than wrapper object calls."
msgstr ""
"既存の定義を置き換えてメソッドを登録します。\n"
"*METH_COEXIST* がない場合、デフォルトでは重複する定義をスキップします。\n"
"スロットラッパーはメソッドテーブルより先に登録されるため、例えば "
"*sq_contains* スロットがあると、:meth:`~object.__contains__` という名前のラッ"
"プされたメソッドが生成され、同じ名前に対応する PyCFunction は登録されませ"
"ん。\n"
"このフラグがある場合、ラッパーオブジェクトの代わりに PyCFunction が登録され、"
"スロットと共存します。\n"
"PyCFunction の呼び出しはラッパーオブジェクトの呼び出しより最適化されているの"
"で、この方法が役立ちます。"
#: ../../c-api/structures.rst:488
msgid ""
"The type object corresponding to Python C method objects. This is available "
"as :class:`types.BuiltinMethodType` in the Python layer."
msgstr ""
msgid ""
"Return true if *op* is an instance of the :c:type:`PyCMethod_Type` type or a "
"subtype of it. This function always succeeds."
msgstr ""
"*op* が :c:type:`PyCMethod_Type` 型またはそのサブタイプのインスタンスなら真を"
"返します。\n"
"この関数は常に成功します。"
msgid ""
"This is the same as :c:func:`PyCMethod_Check`, but does not account for "
"subtypes."
msgstr ":c:func:`PyCMethod_Check` と同じですが、サブタイプは対象にしません。"
msgid ""
"Turn *ml* into a Python :term:`callable` object. The caller must ensure that "
"*ml* outlives the :term:`callable`. Typically, *ml* is defined as a static "
"variable."
msgstr ""
"*ml* を Python の :term:`呼び出し可能 <callable>` オブジェクトにします。\n"
"呼び出し側は、*ml* がその :term:`呼び出し可能 <callable>` オブジェクトより長"
"く存続するようにしなければなりません。\n"
"通常、*ml* は静的変数として定義します。"
msgid ""
"The *self* parameter will be passed as the *self* argument to the C function "
"in ``ml->ml_meth`` when invoked. *self* can be ``NULL``."
msgstr ""
"*self* 引数は、``ml->ml_meth`` の C 関数を呼び出すときに、その関数の *self* "
"引数として渡されます。\n"
"*self* は ``NULL`` にできます。"
msgid ""
"The :term:`callable` object's ``__module__`` attribute can be set from the "
"given *module* argument. *module* should be a Python string, which will be "
"used as name of the module the function is defined in. If unavailable, it "
"can be set to :const:`None` or ``NULL``."
msgstr ""
"渡された *module* 引数から、:term:`呼び出し可能 <callable>` オブジェクトの "
"``__module__`` 属性を設定できます。\n"
"*module* は Python の文字列で、関数の定義元モジュールの名前として使われま"
"す。\n"
"名前が分からない場合は :const:`None` または ``NULL`` にできます。"
msgid ":attr:`function.__module__`"
msgstr ":attr:`function.__module__`"
msgid ""
"The *cls* parameter will be passed as the *defining_class* argument to the C "
"function. Must be set if :c:macro:`METH_METHOD` is set on ``ml->ml_flags``."
msgstr ""
"*cls* 引数は C 関数の *defining_class* 引数として渡されます。\n"
"``ml->ml_flags`` に :c:macro:`METH_METHOD` が設定されている場合は、指定する必"
"要があります。"
msgid ""
"The type object corresponding to Python C function objects. This is "
"available as :class:`types.BuiltinFunctionType` in the Python layer."
msgstr ""
"Python の C 関数オブジェクトに対応する型オブジェクトです。\n"
"Python レベルでは :class:`types.BuiltinFunctionType` として利用できます。"
msgid ""
"Return true if *op* is an instance of the :c:type:`PyCFunction_Type` type or "
"a subtype of it. This function always succeeds."
msgstr ""
"*op* が :c:type:`PyCFunction_Type` 型またはそのサブタイプのインスタンスなら真"
"を返します。\n"
"この関数は常に成功します。"
msgid ""
"This is the same as :c:func:`PyCFunction_Check`, but does not account for "
"subtypes."
msgstr ":c:func:`PyCFunction_Check` と同じですが、サブタイプは対象にしません。"
msgid "Equivalent to ``PyCMethod_New(ml, self, module, NULL)``."
msgstr "``PyCMethod_New(ml, self, module, NULL)`` と同等です。"
msgid "Equivalent to ``PyCMethod_New(ml, self, NULL, NULL)``."
msgstr "``PyCMethod_New(ml, self, NULL, NULL)`` と同等です。"
msgid ""
"Get the function's flags on *func* as they were passed "
"to :c:member:`~PyMethodDef.ml_flags`."
msgstr ""
":c:member:`~PyMethodDef.ml_flags` に渡された、*func* の関数フラグを取得しま"
"す。"
msgid ""
"If *func* is not a C function object, this fails with an exception. *func* "
"must not be ``NULL``."
msgstr ""
"*func* が C 関数オブジェクトでない場合、例外を設定して失敗します。\n"
"*func* は ``NULL`` であってはいけません。"
msgid ""
"This function returns the function's flags on success, and ``-1`` with an "
"exception set on failure."
msgstr ""
"成功すると関数のフラグを返し、失敗すると例外を設定して ``-1`` を返します。"
msgid ""
"This is the same as :c:func:`PyCFunction_GetFlags`, but without error or "
"type checking."
msgstr ""
":c:func:`PyCFunction_GetFlags` と同じですが、エラーや型のチェックを行いませ"
"ん。"
msgid ""
"Get the function pointer on *func* as it was passed "
"to :c:member:`~PyMethodDef.ml_meth`."
msgstr ""
":c:member:`~PyMethodDef.ml_meth` に渡された、*func* の関数ポインタを取得しま"
"す。"
msgid ""
"This function returns the function pointer on success, and ``NULL`` with an "
"exception set on failure."
msgstr ""
"成功すると関数ポインタを返し、失敗すると例外を設定して ``NULL`` を返します。"
msgid ""
"This is the same as :c:func:`PyCFunction_GetFunction`, but without error or "
"type checking."
msgstr ""
":c:func:`PyCFunction_GetFunction` と同じですが、エラーや型のチェックを行いま"
"せん。"
msgid ""
"Get the \"self\" object on *func*. This is the object that would be passed "
"to the first argument of a :c:type:`PyCFunction`. For C function objects "
"created through a :c:type:`PyMethodDef` on a :c:type:`PyModuleDef`, this is "
"the resulting module object."
msgstr ""
"*func* の「self」オブジェクトを取得します。\n"
"これは :c:type:`PyCFunction` の第 1 引数に渡されるオブジェクトです。\n"
":c:type:`PyModuleDef` 上の :c:type:`PyMethodDef` を介して作成した C 関数オブ"
"ジェクトでは、作成されたモジュールオブジェクトになります。"
#: ../../c-api/structures.rst:603
msgid ""
"This function returns a :term:`borrowed reference` to the \"self\" object on "
"success, and ``NULL`` with an exception set on failure."
msgstr ""
msgid ""
"This is the same as :c:func:`PyCFunction_GetSelf`, but without error or type "
"checking."
msgstr ""
":c:func:`PyCFunction_GetSelf` と同じですが、エラーや型のチェックを行いませ"
"ん。"
msgid ""
"Return a :term:`borrowed reference` to the defining class of *func* if "
"its :c:member:`~PyMethodDef.ml_flags` includes :c:macro:`METH_METHOD`. "
"Otherwise, return ``NULL`` without setting an exception."
msgstr ""
"*func* の :c:member:`~PyMethodDef.ml_flags` に :c:macro:`METH_METHOD` が含ま"
"れる場合、定義元クラスへの :term:`借用参照 <borrowed reference>` を返しま"
"す。\n"
"それ以外の場合は、例外を設定せずに ``NULL`` を返します。"
msgid ""
"*func* must be a C function object and must not be ``NULL``. This function "
"does not perform error or type checking."
msgstr ""
"*func* は C 関数オブジェクトでなければならず、``NULL`` にしてはいけません。\n"
"この関数はエラーや型のチェックを行いません。"
msgid "Accessing attributes of extension types"
msgstr "拡張型の属性へのアクセス"
msgid ""
"Structure which describes an attribute of a type which corresponds to a C "
"struct member. When defining a class, put a NULL-terminated array of these "
"structures in the :c:member:`~PyTypeObject.tp_members` slot."
msgstr ""
"C 構造体のメンバーに対応する、型の属性を記述する構造体です。\n"
"クラスを定義するときは、この構造体の NULL で終端した配列"
"を :c:member:`~PyTypeObject.tp_members` スロットに設定します。"
msgid "Its fields are, in order:"
msgstr "フィールドは順に次のとおりです。"
msgid ""
"Name of the member. A NULL value marks the end of a ``PyMemberDef[]`` array."
msgstr ""
"メンバーの名前。\n"
"NULL 値は ``PyMemberDef[]`` 配列の終端を示します。"
msgid "The string should be static, no copy is made of it."
msgstr ""
"文字列は静的に割り当てられている必要があります。\n"
"コピーは作成されません。"
msgid ""
"The type of the member in the C struct. See :ref:`PyMemberDef-types` for the "
"possible values."
msgstr ""
"C 構造体内のメンバーの型。\n"
"使用できる値は :ref:`PyMemberDef-types` を参照してください。"
msgid ""
"The offset in bytes that the member is located on the type’s object struct."
msgstr "その型のオブジェクト構造体内での、メンバーのバイト単位のオフセット。"
msgid ""
"Zero or more of the :ref:`PyMemberDef-flags`, combined using bitwise OR."
msgstr ":ref:`PyMemberDef-flags` を 0 個以上、ビット OR で組み合わせた値。"
msgid ""
"The docstring, or NULL. The string should be static, no copy is made of it. "
"Typically, it is defined using :c:macro:`PyDoc_STR`."
msgstr ""
"ドキュメント文字列、または NULL。\n"
"文字列は静的に割り当てられている必要があり、コピーは作成されません。\n"
"通常は :c:macro:`PyDoc_STR` を使って定義します。"
msgid ""
"By default (when :c:member:`~PyMemberDef.flags` is ``0``), members allow "
"both read and write access. Use the :c:macro:`Py_READONLY` flag for read-"
"only access. Certain types, like :c:macro:`Py_T_STRING`, "
"imply :c:macro:`Py_READONLY`. Only :c:macro:`Py_T_OBJECT_EX` (and "
"legacy :c:macro:`T_OBJECT`) members can be deleted."
msgstr ""
"デフォルト (:c:member:`~PyMemberDef.flags` が ``0`` の場合) では、メンバーは"
"読み書きの両方を許可します。\n"
"読み取り専用にするには :c:macro:`Py_READONLY` フラグを使ってください。\n"
":c:macro:`Py_T_STRING` など、一部の型は :c:macro:`Py_READONLY` を暗黙に指定し"
"ます。\n"
"削除できるのは :c:macro:`Py_T_OBJECT_EX` (および従来の :c:macro:`T_OBJECT`) "
"のメンバーだけです。"
msgid ""
"For heap-allocated types (created using :c:func:`PyType_FromSpec` or "
"similar), ``PyMemberDef`` may contain a definition for the special member "
"``\"__vectorcalloffset__\"``, corresponding "
"to :c:member:`~PyTypeObject.tp_vectorcall_offset` in type objects. This "
"member must be defined with ``Py_T_PYSSIZET``, and either ``Py_READONLY`` or "
"``Py_READONLY | Py_RELATIVE_OFFSET``. For example::"
msgstr ""
"ヒープに割り当てられた型 (:c:func:`PyType_FromSpec` などで作成したもの) で"
"は、型オブジェクトの :c:member:`~PyTypeObject.tp_vectorcall_offset` に対応す"
"る特殊メンバー ``\"__vectorcalloffset__\"`` の定義を ``PyMemberDef`` に含めら"
"れます。\n"
"このメンバーは ``Py_T_PYSSIZET`` と、``Py_READONLY`` または ``Py_READONLY | "
"Py_RELATIVE_OFFSET`` のいずれかで定義しなければなりません。\n"
"例えば次のようにします。 ::"
msgid ""
"static PyMemberDef spam_type_members[] = {\n"
" {\"__vectorcalloffset__\", Py_T_PYSSIZET,\n"
" offsetof(Spam_object, vectorcall), Py_READONLY},\n"
" {NULL} /* Sentinel */\n"
"};"
msgstr ""