From e5ecd7c849c9f5c79a75e31226b6cd44867ec6cf Mon Sep 17 00:00:00 2001 From: Rob Rix Date: Tue, 24 Sep 2019 17:02:01 -0400 Subject: [PATCH] Move the definition of Term up. --- semantic-tags/src/Language/Python/Tags.hs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/semantic-tags/src/Language/Python/Tags.hs b/semantic-tags/src/Language/Python/Tags.hs index 36284deea..8f46c4d02 100644 --- a/semantic-tags/src/Language/Python/Tags.hs +++ b/semantic-tags/src/Language/Python/Tags.hs @@ -18,6 +18,12 @@ import Tags.Tag import qualified Tags.Taggable.Precise as Tags import qualified TreeSitter.Python.AST as Py +newtype Term a = Term { getTerm :: Py.Module a } + +instance Tags.ToTags Term where + tags = tags . getTerm + + class ToTags t where tags :: ( Carrier sig m @@ -27,12 +33,6 @@ class ToTags t where => t Loc -> m () -newtype Term a = Term { getTerm :: Py.Module a } - -instance Tags.ToTags Term where - tags = tags . getTerm - - instance (ToTagsBy strategy t, strategy ~ ToTagsInstance t) => ToTags t where tags = tags' @strategy