<commit_before>-----------------------------------------------------------------------------
--
-- Static flags
--
-- Static flags can only be set once, on the command-line.  Inside GHC,
-- each static flag corresponds to a top-level value, usually of type Bool.
--
-- (c) The University of Glasgow 2005
--
-----------------------------------------------------------------------------

module StaticFlags (
	parseStaticFlags,
	staticFlags,

	-- Ways
	WayName(..), v_Ways, v_Build_tag, v_RTS_Build_tag,

	-- Output style options
	opt_PprUserLength,
	opt_PprStyle_Debug,

	-- profiling opts
	opt_AutoSccsOnAllToplevs,
	opt_AutoSccsOnExportedToplevs,
	opt_AutoSccsOnIndividualCafs,
	opt_SccProfilingOn,
	opt_DoTickyProfiling,

	-- language opts
	opt_DictsStrict,
        opt_MaxContextReductionDepth,
	opt_IrrefutableTuples,
	opt_Parallel,
	opt_SMP,
	opt_RuntimeTypes,
	opt_Flatten,

	-- optimisation opts
	opt_NoMethodSharing, 
	opt_NoStateHack,
	opt_LiberateCaseThreshold,
	opt_CprOff,
	opt_RulesOff,
	opt_SimplNoPreInlining,
	opt_SimplExcessPrecision,
	opt_MaxWorkerArgs,

	-- Unfolding control
	opt_UF_CreationThreshold,
	opt_UF_UseThreshold,
	opt_UF_FunAppDiscount,
	opt_UF_KeenessFactor,
	opt_UF_UpdateInPlace,
	opt_UF_DearOp,

	-- misc opts
	opt_IgnoreDotGhci,
	opt_ErrorSpans,
	opt_EmitCExternDecls,
	opt_GranMacros,
	opt_HiVersion,
	opt_HistorySize,
	opt_OmitBlackHoling,
	opt_Static,
	opt_Unregisterised,
	opt_EmitExternalCore,
	opt_PIC,
	v_Ld_inputs,
  ) where

#include "HsVersions.h"

import DriverPhases
import Util		( consIORef )
import CmdLineParser
import Config		( cProjectVersionInt, cProjectPatchLevel,
			  cGhcUnregisterised )
import FastString	( FastString, mkFastString )
import Util
import Maybes		( firstJust )
import Panic		( GhcException(..), ghcError )
import Constants	( mAX_CONTEXT_REDUCTION_DEPTH )

import EXCEPTION	( throwDyn )
import DATA_IOREF
import UNSAFE_IO	( unsafePerformIO )
import Monad		( when )
import Char		( isDigit )
import List		( sort, intersperse )

-----------------------------------------------------------------------------
-- Static flags

parseStaticFlags :: [String] -> IO [String]<commit_msg>[project @ 2005-06-13 13:46:39 by simonmar] unused imports<commit_after>-----------------------------------------------------------------------------
--
-- Static flags
--
-- Static flags can only be set once, on the command-line.  Inside GHC,
-- each static flag corresponds to a top-level value, usually of type Bool.
--
-- (c) The University of Glasgow 2005
--
-----------------------------------------------------------------------------

module StaticFlags (
	parseStaticFlags,
	staticFlags,

	-- Ways
	WayName(..), v_Ways, v_Build_tag, v_RTS_Build_tag,

	-- Output style options
	opt_PprUserLength,
	opt_PprStyle_Debug,

	-- profiling opts
	opt_AutoSccsOnAllToplevs,
	opt_AutoSccsOnExportedToplevs,
	opt_AutoSccsOnIndividualCafs,
	opt_SccProfilingOn,
	opt_DoTickyProfiling,

	-- language opts
	opt_DictsStrict,
        opt_MaxContextReductionDepth,
	opt_IrrefutableTuples,
	opt_Parallel,
	opt_SMP,
	opt_RuntimeTypes,
	opt_Flatten,

	-- optimisation opts
	opt_NoMethodSharing, 
	opt_NoStateHack,
	opt_LiberateCaseThreshold,
	opt_CprOff,
	opt_RulesOff,
	opt_SimplNoPreInlining,
	opt_SimplExcessPrecision,
	opt_MaxWorkerArgs,

	-- Unfolding control
	opt_UF_CreationThreshold,
	opt_UF_UseThreshold,
	opt_UF_FunAppDiscount,
	opt_UF_KeenessFactor,
	opt_UF_UpdateInPlace,
	opt_UF_DearOp,

	-- misc opts
	opt_IgnoreDotGhci,
	opt_ErrorSpans,
	opt_EmitCExternDecls,
	opt_GranMacros,
	opt_HiVersion,
	opt_HistorySize,
	opt_OmitBlackHoling,
	opt_Static,
	opt_Unregisterised,
	opt_EmitExternalCore,
	opt_PIC,
	v_Ld_inputs,
  ) where

#include "HsVersions.h"

import Util		( consIORef )
import CmdLineParser
import Config		( cProjectVersionInt, cProjectPatchLevel,
			  cGhcUnregisterised )
import FastString	( FastString, mkFastString )
import Util
import Maybes		( firstJust )
import Panic		( GhcException(..), ghcError )
import Constants	( mAX_CONTEXT_REDUCTION_DEPTH )

import EXCEPTION	( throwDyn )
import DATA_IOREF
import UNSAFE_IO	( unsafePerformIO )
import Monad		( when )
import Char		( isDigit )
import List		( sort, intersperse )

-----------------------------------------------------------------------------
-- Static flags

parseStaticFlags :: [String] -> IO [String]
{'fraction_non_alphanumeric': 0.1728766489238602, 'fraction_numerical': 0.0050914140245313586, 'mean_word_length': 2.8866906474820144, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6063822', 'n_tokens_mistral': 1568, 'n_tokens_neox': 1490, 'n_words': 303}