Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commite5fe9a2

Browse files
authored
Merge branch 'master' into repr
2 parents107d22f +7bc2495 commite5fe9a2

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

‎src/runtime/pyobject.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ public object AsManagedObject(Type t)
101101
}
102102
returnresult;
103103
}
104-
104+
105105
/// <summary>
106106
/// As Method
107107
/// </summary>
@@ -1121,10 +1121,10 @@ public override bool TryBinaryOperation(BinaryOperationBinder binder, object arg
11211121
res=Runtime.PyNumber_InPlaceMultiply(this.obj,((PyObject)arg).obj);
11221122
break;
11231123
caseExpressionType.Divide:
1124-
res=Runtime.PyNumber_Divide(this.obj,((PyObject)arg).obj);
1124+
res=Runtime.PyNumber_TrueDivide(this.obj,((PyObject)arg).obj);
11251125
break;
11261126
caseExpressionType.DivideAssign:
1127-
res=Runtime.PyNumber_InPlaceDivide(this.obj,((PyObject)arg).obj);
1127+
res=Runtime.PyNumber_InPlaceTrueDivide(this.obj,((PyObject)arg).obj);
11281128
break;
11291129
caseExpressionType.And:
11301130
res=Runtime.PyNumber_And(this.obj,((PyObject)arg).obj);

‎src/runtime/runtime.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@ public static IntPtr GetProcAddress(IntPtr dllHandle, string name)
105105
publicclassRuntime
106106
{
107107
// C# compiler copies constants to the assemblies that references this library.
108-
// We needs to replace all public constants to static readonly fields to allow
108+
// We needs to replace all public constants to static readonly fields to allow
109109
// binary substitution of different Python.Runtime.dll builds in a target application.
110110

111111
publicstaticintUCS=>_UCS;
@@ -131,7 +131,7 @@ public class Runtime
131131
#endif
132132

133133
// C# compiler copies constants to the assemblies that references this library.
134-
// We needs to replace all public constants to static readonly fields to allow
134+
// We needs to replace all public constants to static readonly fields to allow
135135
// binary substitution of different Python.Runtime.dll builds in a target application.
136136

137137
publicstaticstringpyversion=>_pyversion;
@@ -174,7 +174,7 @@ public class Runtime
174174
#endif
175175

176176
// C# compiler copies constants to the assemblies that references this library.
177-
// We needs to replace all public constants to static readonly fields to allow
177+
// We needs to replace all public constants to static readonly fields to allow
178178
// binary substitution of different Python.Runtime.dll builds in a target application.
179179

180180
publicstaticreadonlystringPythonDLL=_PythonDll;
@@ -1188,7 +1188,7 @@ internal static bool PyFloat_Check(IntPtr ob)
11881188
internalstaticextern IntPtr PyNumber_Multiply(IntPtr o1, IntPtr o2);
11891189

11901190
[DllImport(_PythonDll, CallingConvention= CallingConvention.Cdecl)]
1191-
internalstaticextern IntPtrPyNumber_Divide(IntPtr o1, IntPtr o2);
1191+
internalstaticextern IntPtrPyNumber_TrueDivide(IntPtr o1, IntPtr o2);
11921192

11931193
[DllImport(_PythonDll, CallingConvention= CallingConvention.Cdecl)]
11941194
internalstaticextern IntPtr PyNumber_And(IntPtr o1, IntPtr o2);
@@ -1221,7 +1221,7 @@ internal static bool PyFloat_Check(IntPtr ob)
12211221
internalstaticextern IntPtr PyNumber_InPlaceMultiply(IntPtr o1, IntPtr o2);
12221222

12231223
[DllImport(_PythonDll, CallingConvention= CallingConvention.Cdecl)]
1224-
internalstaticextern IntPtrPyNumber_InPlaceDivide(IntPtr o1, IntPtr o2);
1224+
internalstaticextern IntPtrPyNumber_InPlaceTrueDivide(IntPtr o1, IntPtr o2);
12251225

12261226
[DllImport(_PythonDll, CallingConvention= CallingConvention.Cdecl)]
12271227
internalstaticextern IntPtr PyNumber_InPlaceAnd(IntPtr o1, IntPtr o2);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp