From: simonmar Date: Thu, 27 Jun 2002 15:15:05 +0000 (+0000) Subject: [project @ 2002-06-27 15:15:05 by simonmar] X-Git-Tag: Approx_11550_changesets_converted~1925 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=3d89e057aea938310e8ce88a2cd89f0a2fc37f2d;p=ghc-hetmet.git [project @ 2002-06-27 15:15:05 by simonmar] Don't process OPTIONS in the HsPp phase as well as the cpp phase. Fixes problems with include files appearing twice in stub files. --- diff --git a/ghc/compiler/main/DriverPipeline.hs b/ghc/compiler/main/DriverPipeline.hs index 8f70de4..0cb43c3 100644 --- a/ghc/compiler/main/DriverPipeline.hs +++ b/ghc/compiler/main/DriverPipeline.hs @@ -401,12 +401,9 @@ run_phase Cpp basename suff input_fn output_fn ------------------------------------------------------------------------------- -- HsPp phase -run_phase HsPp basename suff input_fn output_fn - = do src_opts <- getOptionsFromSource input_fn - unhandled_flags <- processArgs dynamic_flags src_opts [] - checkProcessArgsResult unhandled_flags basename suff - let orig_fn = basename ++ '.':suff +run_phase HsPp basename suff input_fn output_fn + = do let orig_fn = basename ++ '.':suff do_pp <- dynFlag ppFlag if not do_pp then -- no need to preprocess, just pass input file along