未验证 提交 fc960f36 编写于 作者: R Richard A Hofer 提交者: GitHub

Add default to offset param of Python generated GetRootAs (#6312)

上级 f437f0f7
......@@ -127,7 +127,7 @@ class PythonGenerator : public BaseGenerator {
code += Indent + "@classmethod\n";
code += Indent + "def GetRootAs";
code += NormalizedName(struct_def);
code += "(cls, buf, offset):";
code += "(cls, buf, offset=0):";
code += "\n";
code += Indent + Indent;
code += "n = flatbuffers.encode.Get";
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册