Browse Source

[cpp] Do not store array values in temp variables in case this causes a copy operation.

hughsando 10 năm trước cách đây
mục cha
commit
88800484e1
1 tập tin đã thay đổi với 1 bổ sung0 xóa
  1. 1 0
      analyzer.ml

+ 1 - 0
analyzer.ml

@@ -236,6 +236,7 @@ module Simplifier = struct
 			with Exit ->
 				begin match follow e.etype with
 					| TAbstract({a_path = [],"Void"},_) -> true
+					| TInst ({ cl_path = [],"Array" }, _) when com.platform = Cpp -> true
 					| _ -> false
 				end
 		in