瀏覽代碼

Merge pull request #128 from psboyce/patch-2

Fix order of members when pickling Token
tags/gm/2021-09-23T00Z/github.com--lark-parser-lark/0.6.0
Erez Shinan 6 年之前
committed by GitHub
父節點
當前提交
b22268db6f
沒有發現已知的金鑰在資料庫的簽署中 GPG 金鑰 ID: 4AEE18F83AFDEB23
共有 1 個檔案被更改,包括 1 行新增1 行删除
  1. +1
    -1
      lark/lexer.py

+ 1
- 1
lark/lexer.py 查看文件

@@ -41,7 +41,7 @@ class Token(Str):
return cls(type_, value, borrow_t.pos_in_stream, line=borrow_t.line, column=borrow_t.column)

def __reduce__(self):
return (self.__class__, (self.type, self.pos_in_stream, self.value, self.line, self.column, ))
return (self.__class__, (self.type, self.value, self.pos_in_stream, self.line, self.column, ))

def __repr__(self):
return 'Token(%s, %r)' % (self.type, self.value)


Loading…
取消
儲存