diff --git a/syntax/printer_test.go b/syntax/printer_test.go
index <HASH>..<HASH> 100644
--- a/syntax/printer_test.go
+++ b/syntax/printer_test.go
@@ -70,7 +70,10 @@ var printTests = []printCase{
 	{"foo\n\n", "foo"},
 	{"\n\nfoo", "foo"},
 	{"# foo \n # bar\t", "# foo\n# bar"},
-	{"#", "#"},
+	samePrint("#"),
+	samePrint("#c1\\\n#c2"),
+	samePrint("#\\\n#"),
+	samePrint("foo\\\\\nbar"),
 	samePrint("a=b # inline\nbar"),
 	samePrint("a=$(b) # inline"),
 	samePrint("foo # inline\n# after"),
syntax: add regression tests involving backslashes

See the previous commit for context.