Get the id from the serialized FuncIR associated with this FuncDecl
(func_ir: JsonDict)
| 233 | # TODO: move this to FuncIR? |
| 234 | @staticmethod |
| 235 | def get_id_from_json(func_ir: JsonDict) -> str: |
| 236 | """Get the id from the serialized FuncIR associated with this FuncDecl""" |
| 237 | decl = func_ir["decl"] |
| 238 | shortname = FuncDecl.compute_shortname(decl["class_name"], decl["name"]) |
| 239 | fullname = decl["module_name"] + "." + shortname |
| 240 | return get_id_from_name(decl["name"], fullname, func_ir["line"]) |
| 241 | |
| 242 | @classmethod |
| 243 | def deserialize(cls, data: JsonDict, ctx: DeserMaps) -> FuncDecl: |
no test coverage detected