diff options
Diffstat (limited to 'src/mem/slicc/ast')
-rw-r--r-- | src/mem/slicc/ast/MethodCallExprAST.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/mem/slicc/ast/MethodCallExprAST.py b/src/mem/slicc/ast/MethodCallExprAST.py index 6a2977533..cfee9b19d 100644 --- a/src/mem/slicc/ast/MethodCallExprAST.py +++ b/src/mem/slicc/ast/MethodCallExprAST.py @@ -160,7 +160,13 @@ class MemberMethodCallExprAST(MethodCallExprAST): if return_type.isInterface: prefix = "static_cast<%s &>" % return_type.c_ident - prefix = "%s((%s)." % (prefix, code) + + if str(obj_type) == "AbstractCacheEntry" or \ + ("interface" in obj_type and + obj_type["interface"] == "AbstractCacheEntry"): + prefix = "%s((*(%s))." % (prefix, code) + else: + prefix = "%s((%s)." % (prefix, code) return obj_type, methodId, prefix |