Closed trishume closed 9 years ago
lol I figured it out, it's a pretty interesting bug. The problem is this code: https://github.com/alexeyr/company-auctex/blob/master/company-auctex.el#L204
It deletes the candidate with re-search-backwards
without escaping the candidate. Since * is a regex special character it searches for things like alignnnn
but doesn't match the asterisk itself.
Should be simple to fix: either use a non-regex search function or escape the candidate. I'm an elisp n00b but I'll try submitting a PR for this.
Completing an environment like
align*
by typingbegali
and moving down to thebegalign*
entry and hitting enter will result in:Notice the extra asterisk after the end tag. This gets rendered and shouldn't be there. This happens with all environments that end with a *.