fixed some bugs for java, python, vim (issue #1)