Issue #627 resolved

Ocaml lexer: Names beginning with _ wrongly lexed

Anonymous created an issue

Hello,

The lexer for Ocaml mistakenly finds an error in

A._a

because the name _a starts with an underscore.

I use Pygments version 1.3.1 (Debian version 1.3.1+dfsg-1).

By the way, I didn’t understand why the regexp for the Name token is different between the state 'root' and the state 'dotted': in both cases it should be r'[a-z_][A-Za-z0-9_\']*', no? (I don't really understand why the A-Z is omitted either, even though the lexer understands capital letters in names in that rule).

Best regards

Samuel Hym

Comments (1)

  1. Log in to comment