-
Notifications
You must be signed in to change notification settings - Fork 774
Expand file tree
/
Copy pathPyMethodFlags.cs
More file actions
38 lines (32 loc) · 939 Bytes
/
PyMethodFlags.cs
File metadata and controls
38 lines (32 loc) · 939 Bytes
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
using System;
namespace Python.Runtime.Native;
[Flags]
enum PyMethodFlags : int
{
[Obsolete]
OLDARGS = 0,
VarArgs = 1,
Keywords = 2,
NoArgs = 4,
O = 8,
Class = 0x10,
Static = 0x20,
/// <summary>
/// Allows a method to be entered even though a slot has
/// already filled the entry. When defined, the flag allows a separate
/// method, "__contains__" for example, to coexist with a defined
/// slot like sq_contains.
/// </summary>
Coexist = 0x40,
/// <remarks>3.10+</remarks>
FastCall = 0x80,
/// <summary>
/// The function stores an
/// additional reference to the class that defines it;
/// both self and class are passed to it.
/// It uses PyCMethodObject instead of PyCFunctionObject.
/// May not be combined with METH_NOARGS, METH_O, METH_CLASS or METH_STATIC.
/// </summary>
/// <remarks>3.9+</remarks>
Method = 0x0200,
}