could be:
Formula:
var strings = intext
.replace(/"([^"\n]|("{2}))*("|\n)/g,function f(x){return x.replace(/'/g,"``");})
.replace(/('|rem\s)(.*_\s*\n)*.*$/igm,"")
.match(/"([^"\n]|("{2}))*("|\n)/g)
.map(function f(x){return x.replace(/``/g,"'")});
since both comments and strings have the same color.
Bookmarks