Browse Source

if method is kept, constructor should be kept also (fixes #6819)

Alexander Kuzmenko 7 years ago
parent
commit
b22bfd1f93
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/optimization/dce.ml

+ 1 - 1
src/optimization/dce.ml

@@ -145,7 +145,7 @@ and mark_field dce c cf stat =
 			| Some (c,_) -> mark_field dce c cf stat
 		end else
 			add cf;
-		if not stat && is_physical_var_field cf then
+		if not stat && is_physical_field cf then
 			match c.cl_constructor with
 				| None -> ()
 				| Some ctor -> mark_field dce c ctor false