on master help sign in
better lookup for operators
28ba8deraichoo
src/Idris/Docs.hs+4−1
@@ -100,11 +100,14 @@ docFun n
100 [args] -> zip argnames args
100 [args] -> zip argnames args
101 _ -> []
101 _ -> []
102 let infixes = idris_infixes i
102 let infixes = idris_infixes i
103− let fixdecls = filter (\(Fix _ x) -> x `isSuffixOf` (show n)) infixes
103+ let fixdecls = filter (\(Fix _ x) -> x == funName n) infixes
104 let f = case fixdecls of
104 let f = case fixdecls of
105 [] -> Nothing
105 [] -> Nothing
106 (Fix x _:_) -> Just x
106 (Fix x _:_) -> Just x
107
107
108 return (Doc n docstr args (delab i ty) f)
108 return (Doc n docstr args (delab i ty) f)
109+ where funName :: Name -> String
110+ funName (UN n) = n
111+ funName (NS n _) = funName n
109
112
110
113