浏览代码

[cpp] Fix is_data_member call

hughsando 8 年之前
父节点
当前提交
30cc779f1b
共有 1 个文件被更改,包括 3 次插入3 次删除
  1. 3 3
      src/generators/gencpp.ml

+ 3 - 3
src/generators/gencpp.ml

@@ -4012,9 +4012,9 @@ let is_dynamic_haxe_method f =
 
 
 let is_data_member field =
-   match field.cf_expr with
-   | Some { eexpr = TFunction function_def } -> is_dynamic_haxe_method field
-   | _ -> true;;
+   match field.cf_kind with
+   | Var _ | Method MethDynamic -> true
+   | _ -> false;;
 
 
 let is_override class_def field =