Skip to content

Commit c80802d

Browse files
committed
Add co_stacksize to code objects
Closes #4545
1 parent 6d71f75 commit c80802d

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

vm/src/builtins/code.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,11 @@ impl PyRef<PyCode> {
213213
self.code.arg_count
214214
}
215215

216+
#[pygetset]
217+
fn co_stacksize(self) -> u32 {
218+
self.code.max_stackdepth
219+
}
220+
216221
#[pygetset]
217222
pub fn co_filename(self) -> PyStrRef {
218223
self.code.source_path.to_owned()

0 commit comments

Comments
 (0)