Skip to content

Commit d98e243

Browse files
committed
Rename is32bit to Is32Bit for naming consistency
1 parent edada03 commit d98e243

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

src/runtime/converter.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -437,7 +437,7 @@ static bool ToPrimitive(IntPtr value, Type obType, out Object result, bool setEr
437437
case TypeCode.Int32:
438438
#if PYTHON2 // Trickery to support 64-bit platforms.
439439

440-
if (Runtime.is32bit)
440+
if (Runtime.Is32Bit)
441441
{
442442
op = Runtime.PyNumber_Int(value);
443443

src/runtime/runtime.cs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -170,14 +170,14 @@ public class Runtime
170170
internal static Object IsFinalizingLock = new Object();
171171
internal static bool IsFinalizing = false;
172172

173-
internal static bool is32bit;
173+
internal static bool Is32Bit;
174174

175175
/// <summary>
176176
/// Initialize the runtime...
177177
/// </summary>
178178
internal static void Initialize()
179179
{
180-
is32bit = IntPtr.Size == 4;
180+
Is32Bit = IntPtr.Size == 4;
181181

182182
if (Runtime.Py_IsInitialized() == 0)
183183
{
@@ -501,7 +501,7 @@ internal unsafe static void XIncref(IntPtr op)
501501
void* p = (void*)op;
502502
if ((void*)0 != p)
503503
{
504-
if (is32bit)
504+
if (Is32Bit)
505505
{
506506
(*(int*)p)++;
507507
}
@@ -524,7 +524,7 @@ internal static unsafe void XDecref(IntPtr op)
524524
void* p = (void*)op;
525525
if ((void*)0 != p)
526526
{
527-
if (is32bit)
527+
if (Is32Bit)
528528
{
529529
--(*(int*)p);
530530
}
@@ -535,11 +535,11 @@ internal static unsafe void XDecref(IntPtr op)
535535
if ((*(int*)p) == 0)
536536
{
537537
// PyObject_HEAD: struct _typeobject *ob_type
538-
void* t = is32bit
538+
void* t = Is32Bit
539539
? (void*)(*((uint*)p + 1))
540540
: (void*)(*((ulong*)p + 1));
541541
// PyTypeObject: destructor tp_dealloc
542-
void* f = is32bit
542+
void* f = Is32Bit
543543
? (void*)(*((uint*)t + 6))
544544
: (void*)(*((ulong*)t + 6));
545545
if ((void*)0 == f)
@@ -558,7 +558,7 @@ internal unsafe static long Refcount(IntPtr op)
558558
void* p = (void*)op;
559559
if ((void*)0 != p)
560560
{
561-
if (is32bit)
561+
if (Is32Bit)
562562
{
563563
return (*(int*)p);
564564
}
@@ -887,7 +887,7 @@ internal unsafe static IntPtr
887887
#else
888888
int n = 1;
889889
#endif
890-
if (is32bit)
890+
if (Is32Bit)
891891
{
892892
return new IntPtr((void*)(*((uint*)p + n)));
893893
}

0 commit comments

Comments
 (0)