We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
-XCPP
The -XCPP language extension is pretty intrusive, interfering with other tools that need to parse the source such as HLint, fourmolu and HLS.
It looks like we have plenty of modules enabling -XCPP but not needing it? Can we remove those redundant language pragmas?
$ grep '^#if' --files-without-match $(grep -R --files-with-matches 'LANGUAGE.*CPP' */**/*.hs) cabal-install/src/Distribution/Client/Check.hs cabal-install/src/Distribution/Client/CmdOutdated.hs cabal-install/src/Distribution/Client/CmdPath.hs cabal-install/src/Distribution/Client/CmdUpdate.hs cabal-install/src/Distribution/Client/Configure.hs cabal-install/src/Distribution/Client/FileMonitor.hs cabal-install/src/Distribution/Client/GenBounds.hs cabal-install/src/Distribution/Client/IndexUtils.hs cabal-install/src/Distribution/Client/InstallSymlink.hs cabal-install/src/Distribution/Client/Main.hs cabal-install/src/Distribution/Client/Manpage.hs cabal-install/src/Distribution/Client/ProjectBuilding.hs cabal-install/src/Distribution/Client/ProjectConfig.hs cabal-install/src/Distribution/Client/ProjectPlanning.hs cabal-install/src/Distribution/Client/Sandbox.hs cabal-install/src/Distribution/Client/Security/HTTP.hs cabal-install/src/Distribution/Client/Targets.hs cabal-install/src/Distribution/Deprecated/ParseUtils.hs cabal-install/src/Distribution/Deprecated/ReadP.hs cabal-install/tests/UnitTests/Distribution/Client/FileMonitor.hs cabal-install/tests/UnitTests/Distribution/Client/Glob.hs cabal-install/tests/UnitTests/Distribution/Client/UserConfig.hs cabal-install/tests/UnitTests/Distribution/Solver/Modular/QuickCheck.hs cabal-install/tests/UnitTests/Distribution/Solver/Types/OptionalStanza.hs Cabal-QuickCheck/src/Test/QuickCheck/GenericArbitrary.hs Cabal-syntax/src/Distribution/Compat/Binary.hs Cabal-syntax/src/Distribution/Compat/Exception.hs Cabal-syntax/src/Distribution/Compat/Graph.hs Cabal-syntax/src/Distribution/Compat/MonadFail.hs Cabal-syntax/src/Distribution/Compat/Newtype.hs Cabal-syntax/src/Distribution/Compat/Prelude.hs Cabal-syntax/src/Distribution/Compat/Semigroup.hs Cabal-syntax/src/Distribution/FieldGrammar/Class.hs Cabal-syntax/src/Distribution/Fields/ParseResult.hs Cabal-syntax/src/Distribution/PackageDescription/Parsec.hs Cabal-syntax/src/Distribution/Parsec.hs Cabal-syntax/src/Distribution/System.hs Cabal-syntax/src/Distribution/Utils/Generic.hs Cabal-tests/tests/UnitTests/Distribution/CabalSpecVersion.hs Cabal-tests/tests/UnitTests/Distribution/Utils/CharSet.hs Cabal-tests/tests/UnitTests/Distribution/Utils/Structured.hs cabal-testsuite/main/cabal-tests.hs cabal-testsuite/PackageTests/Backpack/bkpcabal01/p/P.hs cabal-testsuite/PackageTests/CabalMacros/Mdl.hs cabal-testsuite/PackageTests/CmmSources/src/Demo.hs cabal-testsuite/PackageTests/CmmSourcesDyn/demo/Main.hs cabal-testsuite/PackageTests/CmmSourcesDyn/src/Demo.hs cabal-testsuite/PackageTests/CmmSourcesExe/src/Demo.hs cabal-testsuite/PackageTests/Haddock/CPP.hs cabal-testsuite/PackageTests/PreProcess/Hsc2HsOptionsCC/Main.hs cabal-testsuite/PackageTests/Regression/T5386/Foo.hs cabal-testsuite/src/Test/Cabal/TestCode.hs Cabal-tree-diff/src/Data/TreeDiff/Instances/Cabal.hs Cabal-tree-diff/src/Data/TreeDiff/Instances/CabalLanguage.hs Cabal-tree-diff/src/Data/TreeDiff/Instances/CabalSPDX.hs Cabal-tree-diff/src/Data/TreeDiff/Instances/CabalVersion.hs Cabal/src/Distribution/Compat/Async.hs Cabal/src/Distribution/Compat/ResponseFile.hs Cabal/src/Distribution/Compat/Stack.hs Cabal/src/Distribution/Simple/Build/PathsModule/Z.hs Cabal/src/Distribution/Simple/GHCJS.hs Cabal/src/Distribution/Simple/Setup.hs Cabal/src/Distribution/Simple/Setup/Benchmark.hs Cabal/src/Distribution/Simple/Setup/Build.hs Cabal/src/Distribution/Simple/Setup/Clean.hs Cabal/src/Distribution/Simple/Setup/Common.hs Cabal/src/Distribution/Simple/Setup/Copy.hs Cabal/src/Distribution/Simple/Setup/Global.hs Cabal/src/Distribution/Simple/Setup/Haddock.hs Cabal/src/Distribution/Simple/Setup/Hscolour.hs Cabal/src/Distribution/Simple/Setup/Install.hs Cabal/src/Distribution/Simple/Setup/Register.hs Cabal/src/Distribution/Simple/Setup/Repl.hs Cabal/src/Distribution/Simple/Setup/SDist.hs Cabal/src/Distribution/Simple/Setup/Test.hs Cabal/src/Distribution/Utils/MapAccum.hs Cabal/src/Distribution/Utils/Progress.hs
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
The
-XCPP
language extension is pretty intrusive, interfering with other tools that need to parse the source such as HLint, fourmolu and HLS.It looks like we have plenty of modules enabling
-XCPP
but not needing it? Can we remove those redundant language pragmas?The text was updated successfully, but these errors were encountered: