瀏覽代碼

fix more meta positions (closes #5684)

Simon Krajewski 9 年之前
父節點
當前提交
168cb107ff
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      src/typing/typeload.ml

+ 2 - 2
src/typing/typeload.ml

@@ -47,7 +47,7 @@ let transform_abstract_field com this_t a_t a f =
 		let meta = if Meta.has Meta.MultiType a.a_meta then begin
 			if List.mem AInline f.cff_access then error "MultiType constructors cannot be inline" f.cff_pos;
 			if fu.f_expr <> None then error "MultiType constructors cannot have a body" f.cff_pos;
-			(Meta.Extern,[],f.cff_pos) :: meta
+			(Meta.Extern,[],null_pos) :: meta
 		end else
 			meta
 		in
@@ -216,7 +216,7 @@ let module_pass_1 ctx m tdecls loadp =
 				let this_t = loop d.d_flags in
 				let fields = List.map (transform_abstract_field com this_t a_t a) fields in
 				let meta = ref [] in
-				if has_meta Meta.Dce a.a_meta then meta := (Meta.Dce,[],p) :: !meta;
+				if has_meta Meta.Dce a.a_meta then meta := (Meta.Dce,[],null_pos) :: !meta;
 				let acc = make_decl acc (EClass { d_name = (fst d.d_name) ^ "_Impl_",snd d.d_name; d_flags = [HPrivate]; d_data = fields; d_doc = None; d_params = []; d_meta = !meta },p) in
 				(match !decls with
 				| (TClassDecl c,_) :: _ ->