Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit a3591b6

Browse files
committed
minor improvements
1 parent 05ecbcf commit a3591b6

File tree

1 file changed

+4
-11
lines changed

1 file changed

+4
-11
lines changed

src/runtime/module.cs

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -229,13 +229,10 @@ public PyObject Execute(PyObject script, PyDict? locals = null)
229229
}
230230

231231
/// <summary>
232-
/// Execute method
233-
/// </summary>
234-
/// <remarks>
235-
/// Execute a Python ast and return the result as a PyObject,
232+
/// Execute a Python ast and return the result as a <see cref="PyObject"/>,
236233
/// and convert the result to a Managed Object of given type.
237234
/// The ast can be either an expression or stmts.
238-
/// </remarks>
235+
/// </summary>
239236
public T Execute<T>(PyObject script, PyDict? locals = null)
240237
{
241238
Check();
@@ -245,12 +242,8 @@ public T Execute<T>(PyObject script, PyDict? locals = null)
245242
}
246243

247244
/// <summary>
248-
/// Eval method
245+
/// Evaluate a Python expression and return the result as a <see cref="PyObject"/>.
249246
/// </summary>
250-
/// <remarks>
251-
/// Evaluate a Python expression and return the result as a PyObject
252-
/// or null if an exception is raised.
253-
/// </remarks>
254247
public PyObject Eval(string code, PyDict? locals = null)
255248
{
256249
if (code is null) throw new ArgumentNullException(nameof(code));
@@ -272,7 +265,7 @@ public PyObject Eval(string code, PyDict? locals = null)
272265
/// Evaluate a Python expression
273266
/// and convert the result to a Managed Object of given type.
274267
/// </remarks>
275-
public T Eval<T>(string code, PyDict? locals = null)
268+
public T? Eval<T>(string code, PyDict? locals = null)
276269
{
277270
Check();
278271
PyObject pyObj = Eval(code, locals);

0 commit comments

Comments
 (0)