thanks again for the helpful clarification
- after having parsed compiler error output, highlight the region of
the error and move caret there
Well, AFAIK the error output of Erlang is something like:
./test.erl:5: syntax error before:foo
I suppose you will output the error messages in an HTML window. To jump to a given file and a given line you can use TextMate's URL scheme.
see at http://macromates.com/textmate/manual/ using_textmate_from_terminal section 21.2
Each error would be written as an HTML link à la: <a href="txmt:// open/?url=file://./test.erl&line=5">test.erl:5: syntax error before:foo</a>
Great, that wil do the job !
You wrote "...highlight the region of the error ...". This would mean you have a specific range. But AFAIK one only gets the line number. Or am I wrong?
Oh, consider a line as a region
- source code manipulation such as refactoring, based on AST
Which TMTOOLS function do you would need for that?
I am still looking for it, a function which lets me replace text at given line and position (as position I have token column number, but that can easily be transformed to a regexp)