mirror of
https://github.com/erg-lang/erg.git
synced 2025-10-01 13:11:11 +00:00
Fix #296
This commit is contained in:
parent
debd544fdb
commit
ec4d668189
5 changed files with 25 additions and 20 deletions
|
@ -313,7 +313,7 @@ impl CodeObj {
|
|||
pub fn into_bytes(self, python_ver: PythonVersion) -> Vec<u8> {
|
||||
let mut bytes = vec![DataTypePrefix::Code as u8];
|
||||
bytes.append(&mut self.argcount.to_le_bytes().to_vec());
|
||||
if python_ver.minor >= Some(10) {
|
||||
if python_ver.minor >= Some(8) {
|
||||
bytes.append(&mut self.posonlyargcount.to_le_bytes().to_vec());
|
||||
}
|
||||
bytes.append(&mut self.kwonlyargcount.to_le_bytes().to_vec());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue