Hacker News new | past | comments | ask | show | jobs | submit login

Yup! rust/regex has had this for a while. More recently, its error messages have also gotten a lot better, which I'm proud of!

    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    regex parse error:
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    1: (?x)
    2:       (?P<y>\d{4}) # the year
    3:       -
    4:       (?P<m>*\d{2} # the month
                   ^
    5:       -
    6:       (?P<d>\d{2}) # the day
    7:     
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    error: repetition operator missing expression
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Playground link: https://play.rust-lang.org/?version=stable&mode=debug&editio...



Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: