From 3eddd6b2bb9fa353d3b1059a6dbc23d80df9d812 Mon Sep 17 00:00:00 2001 From: Jeroen Engels Date: Thu, 11 Mar 2021 23:58:23 +0100 Subject: [PATCH] Format binops --- create-dependency/src/DependencyCreator.elm | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/create-dependency/src/DependencyCreator.elm b/create-dependency/src/DependencyCreator.elm index 8256b2d1..c91ed8ae 100644 --- a/create-dependency/src/DependencyCreator.elm +++ b/create-dependency/src/DependencyCreator.elm @@ -66,6 +66,15 @@ formatValue value = }""" +formatBinop binop = + "{ name = " ++ stringify binop.name ++ """ + , comment = """ ++ stringify binop.comment ++ """ + , tipe = """ ++ formatType binop.tipe ++ """ + , associativity = Elm.Docs.""" ++ Debug.toString binop.associativity ++ """ + , precedence = """ ++ String.fromInt binop.precedence ++ """ + }""" + + formatAlias alias_ = "{ name = " ++ stringify alias_.name ++ """ , args = """ ++ listOfThings stringify alias_.args ++ """ @@ -142,7 +151,7 @@ formatModule mod = , comment = """ ++ stringify mod.comment ++ """ , aliases = """ ++ listOfThings formatAlias mod.aliases ++ """ , unions = """ ++ listOfThings formatUnion mod.unions ++ """ - , binops = [] + , binops = """ ++ listOfThings formatBinop mod.binops ++ """ , values = """ ++ listOfThings formatValue mod.values ++ """ }"""