when highlighting finishes in a different thread, the source code may have changed in the mean time, making the tokenization invalid. This can cause coloring to be applied that's off by a few characters, or even exceptions if the file has been shortened. This fix discards the tokenizer result if the file has changed by seeing if there is another queued highlighter job. This has a side effect of causing newly typed text to syntax highlight slower (if you type really fast, or highlighting is slow). Also use the implicit lock in the SingleJobQueue object for synchronization instead of creating another object.
use stderr if it's not empty, previously it always picked stdout and the error messages were being ignored. Also rewrote the error parser to match "file:lineno: msg" and "file:lineno:colno: msg" formats with a regex. The old could would throw exceptions in certian cases, causing the error messages to be hidden.