1
1
mirror of https://github.com/github/semantic.git synced 2024-11-29 02:44:36 +03:00

Rename the language mode types.

This commit is contained in:
Rob Rix 2019-09-25 11:34:08 -04:00
parent d773ca8282
commit 58c5eac144
No known key found for this signature in database
GPG Key ID: F188A01508EA1CF7
2 changed files with 6 additions and 6 deletions

View File

@ -10,8 +10,8 @@ module Data.Language
, codeNavLanguages
, textToLanguage
, languageToText
, LanguageModes(..)
, ASTMode(..)
, PerLanguageModes(..)
, LanguageMode(..)
) where
import Data.Aeson
@ -141,12 +141,12 @@ textToLanguage = \case
_ -> Unknown
newtype LanguageModes = LanguageModes
{ pythonMode :: ASTMode
newtype PerLanguageModes = PerLanguageModes
{ pythonMode :: LanguageMode
}
deriving (Eq, Ord, Show)
data ASTMode
data LanguageMode
= ALaCarte
| Precise
deriving (Bounded, Enum, Eq, Ord, Read, Show)

View File

@ -102,7 +102,7 @@ parseCommand :: Mod CommandFields (Task.TaskEff Builder)
parseCommand = command "parse" (info parseArgumentsParser (progDesc "Generate parse trees for path(s)"))
where
parseArgumentsParser = do
language <- Language.LanguageModes
language <- Language.PerLanguageModes
<$> option auto ( long "python-mode"
<> help "The AST representation to use for Python sources"
<> metavar "ALaCarte|Precise"