@@ -77,12 +77,20 @@ parseErrorToReport path source parseError reason =
7777 )
7878
7979 ObjectField row col ->
80− toSnippet "UNFINISHED OBJECT" row col
80+ toSnippet "EXTRA COMMA" row col
8181 (
8282 "I was partway through parsing a JSON object when I got stuck here:"
8383 ,
8484 D.stack
85− [ D.reflow $ "I was expecting to see a field name next."
85+ [ D.fillSep
86+ ["I","saw","a","comma","right","before","I","got","stuck","here,"
87+ ,"so","I","was","expecting","to","see","a","field","name","like"
88+ ,D.dullyellow "\"type\"","or",D.dullyellow "\"dependencies\"","next."
89+ ]
90+ , D.reflow $
91+ "This error is commonly caused by trailing commas in JSON objects. Those are\
92+ \ actually disallowed by <https://json.org> so check the previous line for a\
93+ \ trailing commas that may need to be deleted."
8694 , objectNote
8795 ]
8896 )