Skip to content

Implement Tactic Featuresets #1398

New issue

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

Merged
merged 7 commits into from
Feb 19, 2021
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Respond to feedback from @wz1000
  • Loading branch information
isovector committed Feb 18, 2021
commit 83a12bdd7d5892d977e175e0866a9eb6dbca1823
6 changes: 0 additions & 6 deletions plugins/hls-tactics-plugin/src/Ide/Plugin/Tactic.hs
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ import Language.LSP.Types.Capabilities
import OccName
import Prelude hiding (span)
import System.Timeout
import Ide.PluginUtils (getPluginConfig)


descriptor :: PluginId -> PluginDescriptor IdeState
Expand Down Expand Up @@ -103,10 +102,6 @@ tacticCmd tac state (TacticParams uri range var_name)
case res of
Left err -> pure $ Left err
Right medit -> do
config <- getConfig
traceMX "config" config
config2 <- getPluginConfig "tactics"
traceMX "plugin config" config2
forM_ medit $ \edit ->
sendRequest
SWorkspaceApplyEdit
Expand Down Expand Up @@ -164,7 +159,6 @@ graftHole
-> Graft (Either String) ParsedSource
graftHole span rtr
| _jIsTopHole (rtr_jdg rtr)
, hasFeature FeatureAgdaSplit (ctxFeatureSet (rtr_ctx rtr))
= graftSmallestDeclsWithM span
$ graftDecl span $ \pats ->
splitToDecl (fst $ last $ ctxDefiningFuncs $ rtr_ctx rtr)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,7 @@ import qualified Data.Text as T
------------------------------------------------------------------------------
-- | All the available features. A 'FeatureSet' describes the ones currently
-- available to the user.
data Feature
= FeatureAgdaSplit
data Feature = CantHaveAnEmptyDataType
deriving (Eq, Ord, Show, Read, Enum, Bounded)


Expand Down