Download Reference Manual
The Developer's Library for D
About Wiki Forums Source Search Contact

Ticket #2071 (new defect)

Opened 13 years ago

Last modified 13 years ago

Replace regex implementation

Reported by: dhasenan Assigned to: dhasenan
Priority: major Milestone: 1.0
Component: Tango Version: 0.99.9 Kai
Keywords: Cc:

Description (Last modified by dhasenan)

Either port an existing regex implementation or provide bindings to it. Need to find a license-compatible implementation.

I'm resolving all regex-related tickets in favor of this.

Options:

Change History

08/03/11 03:30:54 changed by dhasenan

The more I deal with regex, the more problems I find :(

08/04/11 01:18:31 changed by dhasenan

  • description changed.
  • summary changed from Unittests for Regex to Replace regex implementation.

08/04/11 18:57:42 changed by kris

another option:

  • wrap a C API around re2 (C++, from Russ Cox)

We've historically favoured TRE since it's built the "right way" (favors DFA). Larsivi ran into some UTF issue with it in the dim past, but perhaps that's resolved now?

08/05/11 00:56:31 changed by kris

Onig may be the most suitable choice for embedding general-purpose regex functionality ~ it appears to support a wide range of character-encoding within one binary, and is very fast on everything except alternators (it's a backtracking implementation). Onig has a BSD license.

All other candidates I've seen appear to support either utf8 only or wchar_t only (system dependent), so even if they do fast alternators they're still less than ideal for a library attempting to support each of utf8/16/32 ?

08/05/11 01:07:34 changed by kris