From 8d18a0cb2c1da7181b0e1f744e26b21f885f4915 Mon Sep 17 00:00:00 2001 From: Kostis Sagonas Date: Thu, 27 May 2010 09:01:10 +0000 Subject: Cleanup branch 'bg/compiler-cover-and-clean' Commit 329f737c03db51918361e127560a6f700e99028e removed some unused code, but also introduced the need for further clean-ups. Fix a spec so that its return corresponds to reality. Take out code that will never match from a function. --- lib/compiler/src/compile.erl | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'lib/compiler/src/compile.erl') diff --git a/lib/compiler/src/compile.erl b/lib/compiler/src/compile.erl index 08de3059c9..d5dfde6514 100644 --- a/lib/compiler/src/compile.erl +++ b/lib/compiler/src/compile.erl @@ -900,13 +900,8 @@ expand_module(#compile{code=Code,options=Opts0}=St0) -> {ok,St0#compile{module=Mod,options=Opts,code={Mod,Exp,Forms}}}. core_module(#compile{code=Code0,options=Opts}=St) -> - case v3_core:module(Code0, Opts) of - {ok,Code,Ws} -> - {ok,St#compile{code=Code,warnings=St#compile.warnings ++ Ws}}; - {error,Es,Ws} -> - {error,St#compile{warnings=St#compile.warnings ++ Ws, - errors=St#compile.errors ++ Es}} - end. + {ok,Code,Ws} = v3_core:module(Code0, Opts), + {ok,St#compile{code=Code,warnings=St#compile.warnings ++ Ws}}. core_fold_module(#compile{code=Code0,options=Opts,warnings=Warns}=St) -> {ok,Code,Ws} = sys_core_fold:module(Code0, Opts), -- cgit v1.2.3