a2ps 4.14: incorrect VBA strings

Stephen Gildea <[email protected]> Fri, 10 Jul 2009 13:15:51 -0400
Newsgroups gmane.comp.printing.a2ps.bugs
Message-ID <[email protected]>
The definition of a String in vba.ssh is not quite correct.

VBA doesn't use the backslash character-quoting method, so VBA strings
are not C-strings.  Instead, VBA doubles the double-quote.  Some
examples using legal VBA string constants:

FilePath = "C:\"
DblQuote = "a ""quoted"" word"


Here is a patch to handle these strings correctly in a2ps:

--- a2ps-4.14/sheets/vba.ssh	2008-04-08 12:24:05 -0400
+++ a2ps-patched/sheets/vba.ssh	2009-07-10 10:52:45 -0400
@@ -66,7 +66,10 @@
 
 sequences are
     "'" Comment,
-    C-string
+    "\"" Plain String "\"" Plain
+	exceptions are
+	   "\"\""
+	end exceptions
 end sequences
 
 end style