diff --git a/src/codegen.inc.php b/src/codegen.inc.php index d650b49..ae5ac93 100644 --- a/src/codegen.inc.php +++ b/src/codegen.inc.php @@ -393,7 +393,7 @@ function var_sync($fname, \mtgType $type, $buf, array $tokens, $opts) else if($type instanceof \mtgMetaStruct) { if(array_key_exists('virtual', $tokens)) - $str .= "{$fname} = ({$type->getName()})MetaSync.SyncGeneric({$buf}, {$fname}, \"{$key_name}\", {$opts});\n"; + $str .= "{$fname} = MetaSync.SyncGeneric({$buf}, {$fname}, \"{$key_name}\", {$opts});\n"; else $str .= "MetaSync.Sync({$buf}, ref {$fname}, \"{$key_name}\", {$opts});\n"; }