s/(?:^\t|\t$)/-=-|1|-=-/g; s/([^"])(?:\t")/$1-=-|2|-=-/g; s/(?:"\t)([^"])/-=-|3|-=-$1/g; s/"\t"/-=-|4|-=-/g; s/\t//g; #...and then the obvious Opposite Thing