mirror of
https://github.com/github/semantic.git
synced 2024-12-21 05:41:54 +03:00
Make TOC renderer aware of type function field
This commit is contained in:
parent
cf87c11d2c
commit
e9fbded9e8
@ -107,7 +107,7 @@ declarationAlgebra :: (InUnion fs Declaration.Function, InUnion fs Declaration.M
|
||||
-> Source
|
||||
-> RAlgebra (TermF (Union fs) (Record fields)) (Term (Union fs) (Record fields)) (Maybe Declaration)
|
||||
declarationAlgebra proxy source r
|
||||
| Just (Declaration.Function (identifier, _) _ _) <- prj (tailF r) = Just $ FunctionDeclaration (getSource identifier)
|
||||
| Just (Declaration.Function _ (identifier, _) _ _) <- prj (tailF r) = Just $ FunctionDeclaration (getSource identifier)
|
||||
| Just (Declaration.Method (identifier, _) _ _) <- prj (tailF r) = Just $ MethodDeclaration (getSource identifier)
|
||||
| Just (Syntax.Error err) <- prj (tailF r) = Just $ ErrorDeclaration (show (err `asProxyTypeOf` proxy))
|
||||
| otherwise = Nothing
|
||||
|
Loading…
Reference in New Issue
Block a user