PageRenderTime 31ms CodeModel.GetById 23ms RepoModel.GetById 1ms app.codeStats 0ms

/third_party/rust/regex/v1/crate/CHANGELOG.md

https://github.com/chromium/chromium
Markdown | 1021 lines | 788 code | 233 blank | 0 comment | 0 complexity | 4561c3e3a750ad22c5cd593b2c3a30d6 MD5 | raw file
Possible License(s): MPL-2.0-no-copyleft-exception, Apache-2.0, BSD-3-Clause
  1. 1.5.4 (2021-05-06)
  2. ==================
  3. This release fixes another compilation failure when building regex. This time,
  4. the fix is for when the `pattern` feature is enabled, which only works on
  5. nightly Rust. CI has been updated to test this case.
  6. * [BUG #772](https://github.com/rust-lang/regex/pull/772):
  7. Fix build when `pattern` feature is enabled.
  8. 1.5.3 (2021-05-01)
  9. ==================
  10. This releases fixes a bug when building regex with only the `unicode-perl`
  11. feature. It turns out that while CI was building this configuration, it wasn't
  12. actually failing the overall build on a failed compilation.
  13. * [BUG #769](https://github.com/rust-lang/regex/issues/769):
  14. Fix build in `regex-syntax` when only the `unicode-perl` feature is enabled.
  15. 1.5.2 (2021-05-01)
  16. ==================
  17. This release fixes a performance bug when Unicode word boundaries are used.
  18. Namely, for certain regexes on certain inputs, it's possible for the lazy DFA
  19. to stop searching (causing a fallback to a slower engine) when it doesn't
  20. actually need to.
  21. [PR #768](https://github.com/rust-lang/regex/pull/768) fixes the bug, which was
  22. originally reported in
  23. [ripgrep#1860](https://github.com/BurntSushi/ripgrep/issues/1860).
  24. 1.5.1 (2021-04-30)
  25. ==================
  26. This is a patch release that fixes a compilation error when the `perf-literal`
  27. feature is not enabled.
  28. 1.5.0 (2021-04-30)
  29. ==================
  30. This release primarily updates to Rust 2018 (finally) and bumps the MSRV to
  31. Rust 1.41 (from Rust 1.28). Rust 1.41 was chosen because it's still reasonably
  32. old, and is what's in Debian stable at the time of writing.
  33. This release also drops this crate's own bespoke substring search algorithms
  34. in favor of a new
  35. [`memmem` implementation provided by the `memchr` crate](https://docs.rs/memchr/2.4.0/memchr/memmem/index.html).
  36. This will change the performance profile of some regexes, sometimes getting a
  37. little worse, and hopefully more frequently, getting a lot better. Please
  38. report any serious performance regressions if you find them.
  39. 1.4.6 (2021-04-22)
  40. ==================
  41. This is a small patch release that fixes the compiler's size check on how much
  42. heap memory a regex uses. Previously, the compiler did not account for the
  43. heap usage of Unicode character classes. Now it does. It's possible that this
  44. may make some regexes fail to compile that previously did compile. If that
  45. happens, please file an issue.
  46. * [BUG OSS-fuzz#33579](https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=33579):
  47. Some regexes can use more heap memory than one would expect.
  48. 1.4.5 (2021-03-14)
  49. ==================
  50. This is a small patch release that fixes a regression in the size of a `Regex`
  51. in the 1.4.4 release. Prior to 1.4.4, a `Regex` was 552 bytes. In the 1.4.4
  52. release, it was 856 bytes due to internal changes. In this release, a `Regex`
  53. is now 16 bytes. In general, the size of a `Regex` was never something that was
  54. on my radar, but this increased size in the 1.4.4 release seems to have crossed
  55. a threshold and resulted in stack overflows in some programs.
  56. * [BUG #750](https://github.com/rust-lang/regex/pull/750):
  57. Fixes stack overflows seemingly caused by a large `Regex` size by decreasing
  58. its size.
  59. 1.4.4 (2021-03-11)
  60. ==================
  61. This is a small patch release that contains some bug fixes. Notably, it also
  62. drops the `thread_local` (and `lazy_static`, via transitivity) dependencies.
  63. Bug fixes:
  64. * [BUG #362](https://github.com/rust-lang/regex/pull/362):
  65. Memory leaks caused by an internal caching strategy should now be fixed.
  66. * [BUG #576](https://github.com/rust-lang/regex/pull/576):
  67. All regex types now implement `UnwindSafe` and `RefUnwindSafe`.
  68. * [BUG #728](https://github.com/rust-lang/regex/pull/749):
  69. Add missing `Replacer` impls for `Vec<u8>`, `String`, `Cow`, etc.
  70. 1.4.3 (2021-01-08)
  71. ==================
  72. This is a small patch release that adds some missing standard trait
  73. implementations for some types in the public API.
  74. Bug fixes:
  75. * [BUG #734](https://github.com/rust-lang/regex/pull/734):
  76. Add `FusedIterator` and `ExactSizeIterator` impls to iterator types.
  77. * [BUG #735](https://github.com/rust-lang/regex/pull/735):
  78. Add missing `Debug` impls to public API types.
  79. 1.4.2 (2020-11-01)
  80. ==================
  81. This is a small bug fix release that bans `\P{any}`. We previously banned empty
  82. classes like `[^\w\W]`, but missed the `\P{any}` case. In the future, we hope
  83. to permit empty classes.
  84. * [BUG #722](https://github.com/rust-lang/regex/issues/722):
  85. Ban `\P{any}` to avoid a panic in the regex compiler. Found by OSS-Fuzz.
  86. 1.4.1 (2020-10-13)
  87. ==================
  88. This is a small bug fix release that makes `\p{cf}` work. Previously, it would
  89. report "property not found" even though `cf` is a valid abbreviation for the
  90. `Format` general category.
  91. * [BUG #719](https://github.com/rust-lang/regex/issues/719):
  92. Fixes bug that prevented `\p{cf}` from working.
  93. 1.4.0 (2020-10-11)
  94. ==================
  95. This releases has a few minor documentation fixes as well as some very minor
  96. API additions. The MSRV remains at Rust 1.28 for now, but this is intended to
  97. increase to at least Rust 1.41.1 soon.
  98. This release also adds support for OSS-Fuzz. Kudos to
  99. [@DavidKorczynski](https://github.com/DavidKorczynski)
  100. for doing the heavy lifting for that!
  101. New features:
  102. * [FEATURE #649](https://github.com/rust-lang/regex/issues/649):
  103. Support `[`, `]` and `.` in capture group names.
  104. * [FEATURE #687](https://github.com/rust-lang/regex/issues/687):
  105. Add `is_empty` predicate to `RegexSet`.
  106. * [FEATURE #689](https://github.com/rust-lang/regex/issues/689):
  107. Implement `Clone` for `SubCaptureMatches`.
  108. * [FEATURE #715](https://github.com/rust-lang/regex/issues/715):
  109. Add `empty` constructor to `RegexSet` for convenience.
  110. Bug fixes:
  111. * [BUG #694](https://github.com/rust-lang/regex/issues/694):
  112. Fix doc example for `Replacer::replace_append`.
  113. * [BUG #698](https://github.com/rust-lang/regex/issues/698):
  114. Clarify docs for `s` flag when using a `bytes::Regex`.
  115. * [BUG #711](https://github.com/rust-lang/regex/issues/711):
  116. Clarify `is_match` docs to indicate that it can match anywhere in string.
  117. 1.3.9 (2020-05-28)
  118. ==================
  119. This release fixes a MSRV (Minimum Support Rust Version) regression in the
  120. 1.3.8 release. Namely, while 1.3.8 compiles on Rust 1.28, it actually does not
  121. compile on other Rust versions, such as Rust 1.39.
  122. Bug fixes:
  123. * [BUG #685](https://github.com/rust-lang/regex/issues/685):
  124. Remove use of `doc_comment` crate, which cannot be used before Rust 1.43.
  125. 1.3.8 (2020-05-28)
  126. ==================
  127. This release contains a couple of important bug fixes driven
  128. by better support for empty-subexpressions in regexes. For
  129. example, regexes like `b|` are now allowed. Major thanks to
  130. [@sliquister](https://github.com/sliquister) for implementing support for this
  131. in [#677](https://github.com/rust-lang/regex/pull/677).
  132. Bug fixes:
  133. * [BUG #523](https://github.com/rust-lang/regex/pull/523):
  134. Add note to documentation that spaces can be escaped in `x` mode.
  135. * [BUG #524](https://github.com/rust-lang/regex/issues/524):
  136. Add support for empty sub-expressions, including empty alternations.
  137. * [BUG #659](https://github.com/rust-lang/regex/issues/659):
  138. Fix match bug caused by an empty sub-expression miscompilation.
  139. 1.3.7 (2020-04-17)
  140. ==================
  141. This release contains a small bug fix that fixes how `regex` forwards crate
  142. features to `regex-syntax`. In particular, this will reduce recompilations in
  143. some cases.
  144. Bug fixes:
  145. * [BUG #665](https://github.com/rust-lang/regex/pull/665):
  146. Fix feature forwarding to `regex-syntax`.
  147. 1.3.6 (2020-03-24)
  148. ==================
  149. This release contains a sizable (~30%) performance improvement when compiling
  150. some kinds of large regular expressions.
  151. Performance improvements:
  152. * [PERF #657](https://github.com/rust-lang/regex/pull/657):
  153. Improvement performance of compiling large regular expressions.
  154. 1.3.5 (2020-03-12)
  155. ==================
  156. This release updates this crate to Unicode 13.
  157. New features:
  158. * [FEATURE #653](https://github.com/rust-lang/regex/pull/653):
  159. Update `regex-syntax` to Unicode 13.
  160. 1.3.4 (2020-01-30)
  161. ==================
  162. This is a small bug fix release that fixes a bug related to the scoping of
  163. flags in a regex. Namely, before this fix, a regex like `((?i)a)b)` would
  164. match `aB` despite the fact that `b` should not be matched case insensitively.
  165. Bug fixes:
  166. * [BUG #640](https://github.com/rust-lang/regex/issues/640):
  167. Fix bug related to the scoping of flags in a regex.
  168. 1.3.3 (2020-01-09)
  169. ==================
  170. This is a small maintenance release that upgrades the dependency on
  171. `thread_local` from `0.3` to `1.0`. The minimum supported Rust version remains
  172. at Rust 1.28.
  173. 1.3.2 (2020-01-09)
  174. ==================
  175. This is a small maintenance release with some house cleaning and bug fixes.
  176. New features:
  177. * [FEATURE #631](https://github.com/rust-lang/regex/issues/631):
  178. Add a `Match::range` method an a `From<Match> for Range` impl.
  179. Bug fixes:
  180. * [BUG #521](https://github.com/rust-lang/regex/issues/521):
  181. Corrects `/-/.splitn("a", 2)` to return `["a"]` instead of `["a", ""]`.
  182. * [BUG #594](https://github.com/rust-lang/regex/pull/594):
  183. Improve error reporting when writing `\p\`.
  184. * [BUG #627](https://github.com/rust-lang/regex/issues/627):
  185. Corrects `/-/.split("a-")` to return `["a", ""]` instead of `["a"]`.
  186. * [BUG #633](https://github.com/rust-lang/regex/pull/633):
  187. Squash deprecation warnings for the `std::error::Error::description` method.
  188. 1.3.1 (2019-09-04)
  189. ==================
  190. This is a maintenance release with no changes in order to try to work-around
  191. a [docs.rs/Cargo issue](https://github.com/rust-lang/docs.rs/issues/400).
  192. 1.3.0 (2019-09-03)
  193. ==================
  194. This release adds a plethora of new crate features that permit users of regex
  195. to shrink its size considerably, in exchange for giving up either functionality
  196. (such as Unicode support) or runtime performance. When all such features are
  197. disabled, the dependency tree for `regex` shrinks to exactly 1 crate
  198. (`regex-syntax`). More information about the new crate features can be
  199. [found in the docs](https://docs.rs/regex/*/#crate-features).
  200. Note that while this is a new minor version release, the minimum supported
  201. Rust version for this crate remains at `1.28.0`.
  202. New features:
  203. * [FEATURE #474](https://github.com/rust-lang/regex/issues/474):
  204. The `use_std` feature has been deprecated in favor of the `std` feature.
  205. The `use_std` feature will be removed in regex 2. Until then, `use_std` will
  206. remain as an alias for the `std` feature.
  207. * [FEATURE #583](https://github.com/rust-lang/regex/issues/583):
  208. Add a substantial number of crate features shrinking `regex`.
  209. 1.2.1 (2019-08-03)
  210. ==================
  211. This release does a bit of house cleaning. Namely:
  212. * This repository is now using rustfmt.
  213. * License headers have been removed from all files, in following suit with the
  214. Rust project.
  215. * Teddy has been removed from the `regex` crate, and is now part of the
  216. `aho-corasick` crate.
  217. [See `aho-corasick`'s new `packed` sub-module for details](https://docs.rs/aho-corasick/0.7.6/aho_corasick/packed/index.html).
  218. * The `utf8-ranges` crate has been deprecated, with its functionality moving
  219. into the
  220. [`utf8` sub-module of `regex-syntax`](https://docs.rs/regex-syntax/0.6.11/regex_syntax/utf8/index.html).
  221. * The `ucd-util` dependency has been dropped, in favor of implementing what
  222. little we need inside of `regex-syntax` itself.
  223. In general, this is part of an ongoing (long term) effort to make optimizations
  224. in the regex engine easier to reason about. The current code is too convoluted
  225. and thus it is very easy to introduce new bugs. This simplification effort is
  226. the primary motivation behind re-working the `aho-corasick` crate to not only
  227. bundle algorithms like Teddy, but to also provide regex-like match semantics
  228. automatically.
  229. Moving forward, the plan is to join up with the `bstr` and `regex-automata`
  230. crates, with the former providing more sophisticated substring search
  231. algorithms (thereby deleting existing code in `regex`) and the latter providing
  232. ahead-of-time compiled DFAs for cases where they are inexpensive to compute.
  233. 1.2.0 (2019-07-20)
  234. ==================
  235. This release updates regex's minimum supported Rust version to 1.28, which was
  236. release almost 1 year ago. This release also updates regex's Unicode data
  237. tables to 12.1.0.
  238. 1.1.9 (2019-07-06)
  239. ==================
  240. This release contains a bug fix that caused regex's tests to fail, due to a
  241. dependency on an unreleased behavior in regex-syntax.
  242. * [BUG #593](https://github.com/rust-lang/regex/issues/593):
  243. Move an integration-style test on error messages into regex-syntax.
  244. 1.1.8 (2019-07-04)
  245. ==================
  246. This release contains a few small internal refactorings. One of which fixes
  247. an instance of undefined behavior in a part of the SIMD code.
  248. Bug fixes:
  249. * [BUG #545](https://github.com/rust-lang/regex/issues/545):
  250. Improves error messages when a repetition operator is used without a number.
  251. * [BUG #588](https://github.com/rust-lang/regex/issues/588):
  252. Removes use of a repr(Rust) union used for type punning in the Teddy matcher.
  253. * [BUG #591](https://github.com/rust-lang/regex/issues/591):
  254. Update docs for running benchmarks and improve failure modes.
  255. 1.1.7 (2019-06-09)
  256. ==================
  257. This release fixes up a few warnings as a result of recent deprecations.
  258. 1.1.6 (2019-04-16)
  259. ==================
  260. This release fixes a regression introduced by a bug fix (for
  261. [BUG #557](https://github.com/rust-lang/regex/issues/557)) which could cause
  262. the regex engine to enter an infinite loop. This bug was originally
  263. [reported against ripgrep](https://github.com/BurntSushi/ripgrep/issues/1247).
  264. 1.1.5 (2019-04-01)
  265. ==================
  266. This release fixes a bug in regex's dependency specification where it requires
  267. a newer version of regex-syntax, but this wasn't communicated correctly in the
  268. Cargo.toml. This would have been caught by a minimal version check, but this
  269. check was disabled because the `rand` crate itself advertises incorrect
  270. dependency specifications.
  271. Bug fixes:
  272. * [BUG #570](https://github.com/rust-lang/regex/pull/570):
  273. Fix regex-syntax minimal version.
  274. 1.1.4 (2019-03-31)
  275. ==================
  276. This release fixes a backwards compatibility regression where Regex was no
  277. longer UnwindSafe. This was caused by the upgrade to aho-corasick 0.7, whose
  278. AhoCorasick type was itself not UnwindSafe. This has been fixed in aho-corasick
  279. 0.7.4, which we now require.
  280. Bug fixes:
  281. * [BUG #568](https://github.com/rust-lang/regex/pull/568):
  282. Fix an API regression where Regex was no longer UnwindSafe.
  283. 1.1.3 (2019-03-30)
  284. ==================
  285. This releases fixes a few bugs and adds a performance improvement when a regex
  286. is a simple alternation of literals.
  287. Performance improvements:
  288. * [OPT #566](https://github.com/rust-lang/regex/pull/566):
  289. Upgrades `aho-corasick` to 0.7 and uses it for `foo|bar|...|quux` regexes.
  290. Bug fixes:
  291. * [BUG #527](https://github.com/rust-lang/regex/issues/527):
  292. Fix a bug where the parser would panic on patterns like `((?x))`.
  293. * [BUG #555](https://github.com/rust-lang/regex/issues/555):
  294. Fix a bug where the parser would panic on patterns like `(?m){1,1}`.
  295. * [BUG #557](https://github.com/rust-lang/regex/issues/557):
  296. Fix a bug where captures could lead to an incorrect match.
  297. 1.1.2 (2019-02-27)
  298. ==================
  299. This release fixes a bug found in the fix introduced in 1.1.1.
  300. Bug fixes:
  301. * [BUG edf45e6f](https://github.com/rust-lang/regex/commit/edf45e6f):
  302. Fix bug introduced in reverse suffix literal matcher in the 1.1.1 release.
  303. 1.1.1 (2019-02-27)
  304. ==================
  305. This is a small release with one fix for a bug caused by literal optimizations.
  306. Bug fixes:
  307. * [BUG 661bf53d](https://github.com/rust-lang/regex/commit/661bf53d):
  308. Fixes a bug in the reverse suffix literal optimization. This was originally
  309. reported
  310. [against ripgrep](https://github.com/BurntSushi/ripgrep/issues/1203).
  311. 1.1.0 (2018-11-30)
  312. ==================
  313. This is a small release with a couple small enhancements. This release also
  314. increases the minimal supported Rust version (MSRV) to 1.24.1 (from 1.20.0). In
  315. accordance with this crate's MSRV policy, this release bumps the minor version
  316. number.
  317. Performance improvements:
  318. * [OPT #511](https://github.com/rust-lang/regex/pull/511),
  319. [OPT #540](https://github.com/rust-lang/regex/pull/540):
  320. Improve lazy DFA construction for large regex sets.
  321. New features:
  322. * [FEATURE #538](https://github.com/rust-lang/regex/pull/538):
  323. Add Emoji and "break" Unicode properties. See [UNICODE.md](UNICODE.md).
  324. Bug fixes:
  325. * [BUG #530](https://github.com/rust-lang/regex/pull/530):
  326. Add Unicode license (for data tables).
  327. * Various typo/doc fixups.
  328. 1.0.6 (2018-11-06)
  329. ==================
  330. This is a small release.
  331. Performance improvements:
  332. * [OPT #513](https://github.com/rust-lang/regex/pull/513):
  333. Improve performance of compiling large Unicode classes by 8-10%.
  334. Bug fixes:
  335. * [BUG #533](https://github.com/rust-lang/regex/issues/533):
  336. Fix definition of `[[:blank:]]` class that regressed in `regex-syntax 0.5`.
  337. 1.0.5 (2018-09-06)
  338. ==================
  339. This is a small release with an API enhancement.
  340. New features:
  341. * [FEATURE #509](https://github.com/rust-lang/regex/pull/509):
  342. Generalize impls of the `Replacer` trait.
  343. 1.0.4 (2018-08-25)
  344. ==================
  345. This is a small release that bumps the quickcheck dependency.
  346. 1.0.3 (2018-08-24)
  347. ==================
  348. This is a small bug fix release.
  349. Bug fixes:
  350. * [BUG #504](https://github.com/rust-lang/regex/pull/504):
  351. Fix for Cargo's "minimal version" support.
  352. * [BUG 1e39165f](https://github.com/rust-lang/regex/commit/1e39165f):
  353. Fix doc examples for byte regexes.
  354. 1.0.2 (2018-07-18)
  355. ==================
  356. This release exposes some new lower level APIs on `Regex` that permit
  357. amortizing allocation and controlling the location at which a search is
  358. performed in a more granular way. Most users of the regex crate will not
  359. need or want to use these APIs.
  360. New features:
  361. * [FEATURE #493](https://github.com/rust-lang/regex/pull/493):
  362. Add a few lower level APIs for amortizing allocation and more fine grained
  363. searching.
  364. Bug fixes:
  365. * [BUG 3981d2ad](https://github.com/rust-lang/regex/commit/3981d2ad):
  366. Correct outdated documentation on `RegexBuilder::dot_matches_new_line`.
  367. * [BUG 7ebe4ae0](https://github.com/rust-lang/regex/commit/7ebe4ae0):
  368. Correct outdated documentation on `Parser::allow_invalid_utf8` in the
  369. `regex-syntax` crate.
  370. * [BUG 24c7770b](https://github.com/rust-lang/regex/commit/24c7770b):
  371. Fix a bug in the HIR printer where it wouldn't correctly escape meta
  372. characters in character classes.
  373. 1.0.1 (2018-06-19)
  374. ==================
  375. This release upgrades regex's Unicode tables to Unicode 11, and enables SIMD
  376. optimizations automatically on Rust stable (1.27 or newer).
  377. New features:
  378. * [FEATURE #486](https://github.com/rust-lang/regex/pull/486):
  379. Implement `size_hint` on `RegexSet` match iterators.
  380. * [FEATURE #488](https://github.com/rust-lang/regex/pull/488):
  381. Update Unicode tables for Unicode 11.
  382. * [FEATURE #490](https://github.com/rust-lang/regex/pull/490):
  383. SIMD optimizations are now enabled automatically in Rust stable, for versions
  384. 1.27 and up. No compilation flags or features need to be set. CPU support
  385. SIMD is detected automatically at runtime.
  386. Bug fixes:
  387. * [BUG #482](https://github.com/rust-lang/regex/pull/482):
  388. Present a better compilation error when the `use_std` feature isn't used.
  389. 1.0.0 (2018-05-01)
  390. ==================
  391. This release marks the 1.0 release of regex.
  392. While this release includes some breaking changes, most users of older versions
  393. of the regex library should be able to migrate to 1.0 by simply bumping the
  394. version number. The important changes are as follows:
  395. * We adopt Rust 1.20 as the new minimum supported version of Rust for regex.
  396. We also tentativley adopt a policy that permits bumping the minimum supported
  397. version of Rust in minor version releases of regex, but no patch releases.
  398. That is, with respect to semver, we do not strictly consider bumping the
  399. minimum version of Rust to be a breaking change, but adopt a conservative
  400. stance as a compromise.
  401. * Octal syntax in regular expressions has been disabled by default. This
  402. permits better error messages that inform users that backreferences aren't
  403. available. Octal syntax can be re-enabled via the corresponding option on
  404. `RegexBuilder`.
  405. * `(?-u:\B)` is no longer allowed in Unicode regexes since it can match at
  406. invalid UTF-8 code unit boundaries. `(?-u:\b)` is still allowed in Unicode
  407. regexes.
  408. * The `From<regex_syntax::Error>` impl has been removed. This formally removes
  409. the public dependency on `regex-syntax`.
  410. * A new feature, `use_std`, has been added and enabled by default. Disabling
  411. the feature will result in a compilation error. In the future, this may
  412. permit us to support `no_std` environments (w/ `alloc`) in a backwards
  413. compatible way.
  414. For more information and discussion, please see
  415. [1.0 release tracking issue](https://github.com/rust-lang/regex/issues/457).
  416. 0.2.11 (2018-05-01)
  417. ===================
  418. This release primarily contains bug fixes. Some of them resolve bugs where
  419. the parser could panic.
  420. New features:
  421. * [FEATURE #459](https://github.com/rust-lang/regex/pull/459):
  422. Include C++'s standard regex library and Boost's regex library in the
  423. benchmark harness. We now include D/libphobos, C++/std, C++/boost, Oniguruma,
  424. PCRE1, PCRE2, RE2 and Tcl in the harness.
  425. Bug fixes:
  426. * [BUG #445](https://github.com/rust-lang/regex/issues/445):
  427. Clarify order of indices returned by RegexSet match iterator.
  428. * [BUG #461](https://github.com/rust-lang/regex/issues/461):
  429. Improve error messages for invalid regexes like `[\d-a]`.
  430. * [BUG #464](https://github.com/rust-lang/regex/issues/464):
  431. Fix a bug in the error message pretty printer that could cause a panic when
  432. a regex contained a literal `\n` character.
  433. * [BUG #465](https://github.com/rust-lang/regex/issues/465):
  434. Fix a panic in the parser that was caused by applying a repetition operator
  435. to `(?flags)`.
  436. * [BUG #466](https://github.com/rust-lang/regex/issues/466):
  437. Fix a bug where `\pC` was not recognized as an alias for `\p{Other}`.
  438. * [BUG #470](https://github.com/rust-lang/regex/pull/470):
  439. Fix a bug where literal searches did more work than necessary for anchored
  440. regexes.
  441. 0.2.10 (2018-03-16)
  442. ===================
  443. This release primarily updates the regex crate to changes made in `std::arch`
  444. on nightly Rust.
  445. New features:
  446. * [FEATURE #458](https://github.com/rust-lang/regex/pull/458):
  447. The `Hir` type in `regex-syntax` now has a printer.
  448. 0.2.9 (2018-03-12)
  449. ==================
  450. This release introduces a new nightly only feature, `unstable`, which enables
  451. SIMD optimizations for certain types of regexes. No additional compile time
  452. options are necessary, and the regex crate will automatically choose the
  453. best CPU features at run time. As a result, the `simd` (nightly only) crate
  454. dependency has been dropped.
  455. New features:
  456. * [FEATURE #456](https://github.com/rust-lang/regex/pull/456):
  457. The regex crate now includes AVX2 optimizations in addition to the extant
  458. SSSE3 optimization.
  459. Bug fixes:
  460. * [BUG #455](https://github.com/rust-lang/regex/pull/455):
  461. Fix a bug where `(?x)[ / - ]` failed to parse.
  462. 0.2.8 (2018-03-12)
  463. ==================
  464. Bug gixes:
  465. * [BUG #454](https://github.com/rust-lang/regex/pull/454):
  466. Fix a bug in the nest limit checker being too aggressive.
  467. 0.2.7 (2018-03-07)
  468. ==================
  469. This release includes a ground-up rewrite of the regex-syntax crate, which has
  470. been in development for over a year.
  471. New features:
  472. * Error messages for invalid regexes have been greatly improved. You get these
  473. automatically; you don't need to do anything. In addition to better
  474. formatting, error messages will now explicitly call out the use of look
  475. around. When regex 1.0 is released, this will happen for backreferences as
  476. well.
  477. * Full support for intersection, difference and symmetric difference of
  478. character classes. These can be used via the `&&`, `--` and `~~` binary
  479. operators within classes.
  480. * A Unicode Level 1 conformat implementation of `\p{..}` character classes.
  481. Things like `\p{scx:Hira}`, `\p{age:3.2}` or `\p{Changes_When_Casefolded}`
  482. now work. All property name and value aliases are supported, and properties
  483. are selected via loose matching. e.g., `\p{Greek}` is the same as
  484. `\p{G r E e K}`.
  485. * A new `UNICODE.md` document has been added to this repository that
  486. exhaustively documents support for UTS#18.
  487. * Empty sub-expressions are now permitted in most places. That is, `()+` is
  488. now a valid regex.
  489. * Almost everything in regex-syntax now uses constant stack space, even when
  490. performing anaylsis that requires structural induction. This reduces the risk
  491. of a user provided regular expression causing a stack overflow.
  492. * [FEATURE #174](https://github.com/rust-lang/regex/issues/174):
  493. The `Ast` type in `regex-syntax` now contains span information.
  494. * [FEATURE #424](https://github.com/rust-lang/regex/issues/424):
  495. Support `\u`, `\u{...}`, `\U` and `\U{...}` syntax for specifying code points
  496. in a regular expression.
  497. * [FEATURE #449](https://github.com/rust-lang/regex/pull/449):
  498. Add a `Replace::by_ref` adapter for use of a replacer without consuming it.
  499. Bug fixes:
  500. * [BUG #446](https://github.com/rust-lang/regex/issues/446):
  501. We re-enable the Boyer-Moore literal matcher.
  502. 0.2.6 (2018-02-08)
  503. ==================
  504. Bug fixes:
  505. * [BUG #446](https://github.com/rust-lang/regex/issues/446):
  506. Fixes a bug in the new Boyer-Moore searcher that results in a match failure.
  507. We fix this bug by temporarily disabling Boyer-Moore.
  508. 0.2.5 (2017-12-30)
  509. ==================
  510. Bug fixes:
  511. * [BUG #437](https://github.com/rust-lang/regex/issues/437):
  512. Fixes a bug in the new Boyer-Moore searcher that results in a panic.
  513. 0.2.4 (2017-12-30)
  514. ==================
  515. New features:
  516. * [FEATURE #348](https://github.com/rust-lang/regex/pull/348):
  517. Improve performance for capture searches on anchored regex.
  518. (Contributed by @ethanpailes. Nice work!)
  519. * [FEATURE #419](https://github.com/rust-lang/regex/pull/419):
  520. Expand literal searching to include Tuned Boyer-Moore in some cases.
  521. (Contributed by @ethanpailes. Nice work!)
  522. Bug fixes:
  523. * [BUG](https://github.com/rust-lang/regex/pull/436):
  524. The regex compiler plugin has been removed.
  525. * [BUG](https://github.com/rust-lang/regex/pull/436):
  526. `simd` has been bumped to `0.2.1`, which fixes a Rust nightly build error.
  527. * [BUG](https://github.com/rust-lang/regex/pull/436):
  528. Bring the benchmark harness up to date.
  529. 0.2.3 (2017-11-30)
  530. ==================
  531. New features:
  532. * [FEATURE #374](https://github.com/rust-lang/regex/pull/374):
  533. Add `impl From<Match> for &str`.
  534. * [FEATURE #380](https://github.com/rust-lang/regex/pull/380):
  535. Derive `Clone` and `PartialEq` on `Error`.
  536. * [FEATURE #400](https://github.com/rust-lang/regex/pull/400):
  537. Update to Unicode 10.
  538. Bug fixes:
  539. * [BUG #375](https://github.com/rust-lang/regex/issues/375):
  540. Fix a bug that prevented the bounded backtracker from terminating.
  541. * [BUG #393](https://github.com/rust-lang/regex/issues/393),
  542. [BUG #394](https://github.com/rust-lang/regex/issues/394):
  543. Fix bug with `replace` methods for empty matches.
  544. 0.2.2 (2017-05-21)
  545. ==================
  546. New features:
  547. * [FEATURE #341](https://github.com/rust-lang/regex/issues/341):
  548. Support nested character classes and intersection operation.
  549. For example, `[\p{Greek}&&\pL]` matches greek letters and
  550. `[[0-9]&&[^4]]` matches every decimal digit except `4`.
  551. (Much thanks to @robinst, who contributed this awesome feature.)
  552. Bug fixes:
  553. * [BUG #321](https://github.com/rust-lang/regex/issues/321):
  554. Fix bug in literal extraction and UTF-8 decoding.
  555. * [BUG #326](https://github.com/rust-lang/regex/issues/326):
  556. Add documentation tip about the `(?x)` flag.
  557. * [BUG #333](https://github.com/rust-lang/regex/issues/333):
  558. Show additional replacement example using curly braces.
  559. * [BUG #334](https://github.com/rust-lang/regex/issues/334):
  560. Fix bug when resolving captures after a match.
  561. * [BUG #338](https://github.com/rust-lang/regex/issues/338):
  562. Add example that uses `Captures::get` to API documentation.
  563. * [BUG #353](https://github.com/rust-lang/regex/issues/353):
  564. Fix RegexSet bug that caused match failure in some cases.
  565. * [BUG #354](https://github.com/rust-lang/regex/pull/354):
  566. Fix panic in parser when `(?x)` is used.
  567. * [BUG #358](https://github.com/rust-lang/regex/issues/358):
  568. Fix literal optimization bug with RegexSet.
  569. * [BUG #359](https://github.com/rust-lang/regex/issues/359):
  570. Fix example code in README.
  571. * [BUG #365](https://github.com/rust-lang/regex/pull/365):
  572. Fix bug in `rure_captures_len` in the C binding.
  573. * [BUG #367](https://github.com/rust-lang/regex/issues/367):
  574. Fix byte class bug that caused a panic.
  575. 0.2.1
  576. =====
  577. One major bug with `replace_all` has been fixed along with a couple of other
  578. touchups.
  579. * [BUG #312](https://github.com/rust-lang/regex/issues/312):
  580. Fix documentation for `NoExpand` to reference correct lifetime parameter.
  581. * [BUG #314](https://github.com/rust-lang/regex/issues/314):
  582. Fix a bug with `replace_all` when replacing a match with the empty string.
  583. * [BUG #316](https://github.com/rust-lang/regex/issues/316):
  584. Note a missing breaking change from the `0.2.0` CHANGELOG entry.
  585. (`RegexBuilder::compile` was renamed to `RegexBuilder::build`.)
  586. * [BUG #324](https://github.com/rust-lang/regex/issues/324):
  587. Compiling `regex` should only require one version of `memchr` crate.
  588. 0.2.0
  589. =====
  590. This is a new major release of the regex crate, and is an implementation of the
  591. [regex 1.0 RFC](https://github.com/rust-lang/rfcs/blob/master/text/1620-regex-1.0.md).
  592. We are releasing a `0.2` first, and if there are no major problems, we will
  593. release a `1.0` shortly. For `0.2`, the minimum *supported* Rust version is
  594. 1.12.
  595. There are a number of **breaking changes** in `0.2`. They are split into two
  596. types. The first type correspond to breaking changes in regular expression
  597. syntax. The second type correspond to breaking changes in the API.
  598. Breaking changes for regex syntax:
  599. * POSIX character classes now require double bracketing. Previously, the regex
  600. `[:upper:]` would parse as the `upper` POSIX character class. Now it parses
  601. as the character class containing the characters `:upper:`. The fix to this
  602. change is to use `[[:upper:]]` instead. Note that variants like
  603. `[[:upper:][:blank:]]` continue to work.
  604. * The character `[` must always be escaped inside a character class.
  605. * The characters `&`, `-` and `~` must be escaped if any one of them are
  606. repeated consecutively. For example, `[&]`, `[\&]`, `[\&\&]`, `[&-&]` are all
  607. equivalent while `[&&]` is illegal. (The motivation for this and the prior
  608. change is to provide a backwards compatible path for adding character class
  609. set notation.)
  610. * A `bytes::Regex` now has Unicode mode enabled by default (like the main
  611. `Regex` type). This means regexes compiled with `bytes::Regex::new` that
  612. don't have the Unicode flag set should add `(?-u)` to recover the original
  613. behavior.
  614. Breaking changes for the regex API:
  615. * `find` and `find_iter` now **return `Match` values instead of
  616. `(usize, usize)`.** `Match` values have `start` and `end` methods, which
  617. return the match offsets. `Match` values also have an `as_str` method,
  618. which returns the text of the match itself.
  619. * The `Captures` type now only provides a single iterator over all capturing
  620. matches, which should replace uses of `iter` and `iter_pos`. Uses of
  621. `iter_named` should use the `capture_names` method on `Regex`.
  622. * The `at` method on the `Captures` type has been renamed to `get`, and it
  623. now returns a `Match`. Similarly, the `name` method on `Captures` now returns
  624. a `Match`.
  625. * The `replace` methods now return `Cow` values. The `Cow::Borrowed` variant
  626. is returned when no replacements are made.
  627. * The `Replacer` trait has been completely overhauled. This should only
  628. impact clients that implement this trait explicitly. Standard uses of
  629. the `replace` methods should continue to work unchanged. If you implement
  630. the `Replacer` trait, please consult the new documentation.
  631. * The `quote` free function has been renamed to `escape`.
  632. * The `Regex::with_size_limit` method has been removed. It is replaced by
  633. `RegexBuilder::size_limit`.
  634. * The `RegexBuilder` type has switched from owned `self` method receivers to
  635. `&mut self` method receivers. Most uses will continue to work unchanged, but
  636. some code may require naming an intermediate variable to hold the builder.
  637. * The `compile` method on `RegexBuilder` has been renamed to `build`.
  638. * The free `is_match` function has been removed. It is replaced by compiling
  639. a `Regex` and calling its `is_match` method.
  640. * The `PartialEq` and `Eq` impls on `Regex` have been dropped. If you relied
  641. on these impls, the fix is to define a wrapper type around `Regex`, impl
  642. `Deref` on it and provide the necessary impls.
  643. * The `is_empty` method on `Captures` has been removed. This always returns
  644. `false`, so its use is superfluous.
  645. * The `Syntax` variant of the `Error` type now contains a string instead of
  646. a `regex_syntax::Error`. If you were examining syntax errors more closely,
  647. you'll need to explicitly use the `regex_syntax` crate to re-parse the regex.
  648. * The `InvalidSet` variant of the `Error` type has been removed since it is
  649. no longer used.
  650. * Most of the iterator types have been renamed to match conventions. If you
  651. were using these iterator types explicitly, please consult the documentation
  652. for its new name. For example, `RegexSplits` has been renamed to `Split`.
  653. A number of bugs have been fixed:
  654. * [BUG #151](https://github.com/rust-lang/regex/issues/151):
  655. The `Replacer` trait has been changed to permit the caller to control
  656. allocation.
  657. * [BUG #165](https://github.com/rust-lang/regex/issues/165):
  658. Remove the free `is_match` function.
  659. * [BUG #166](https://github.com/rust-lang/regex/issues/166):
  660. Expose more knobs (available in `0.1`) and remove `with_size_limit`.
  661. * [BUG #168](https://github.com/rust-lang/regex/issues/168):
  662. Iterators produced by `Captures` now have the correct lifetime parameters.
  663. * [BUG #175](https://github.com/rust-lang/regex/issues/175):
  664. Fix a corner case in the parsing of POSIX character classes.
  665. * [BUG #178](https://github.com/rust-lang/regex/issues/178):
  666. Drop the `PartialEq` and `Eq` impls on `Regex`.
  667. * [BUG #179](https://github.com/rust-lang/regex/issues/179):
  668. Remove `is_empty` from `Captures` since it always returns false.
  669. * [BUG #276](https://github.com/rust-lang/regex/issues/276):
  670. Position of named capture can now be retrieved from a `Captures`.
  671. * [BUG #296](https://github.com/rust-lang/regex/issues/296):
  672. Remove winapi/kernel32-sys dependency on UNIX.
  673. * [BUG #307](https://github.com/rust-lang/regex/issues/307):
  674. Fix error on emscripten.
  675. 0.1.80
  676. ======
  677. * [PR #292](https://github.com/rust-lang/regex/pull/292):
  678. Fixes bug #291, which was introduced by PR #290.
  679. 0.1.79
  680. ======
  681. * Require regex-syntax 0.3.8.
  682. 0.1.78
  683. ======
  684. * [PR #290](https://github.com/rust-lang/regex/pull/290):
  685. Fixes bug #289, which caused some regexes with a certain combination
  686. of literals to match incorrectly.
  687. 0.1.77
  688. ======
  689. * [PR #281](https://github.com/rust-lang/regex/pull/281):
  690. Fixes bug #280 by disabling all literal optimizations when a pattern
  691. is partially anchored.
  692. 0.1.76
  693. ======
  694. * Tweak criteria for using the Teddy literal matcher.
  695. 0.1.75
  696. ======
  697. * [PR #275](https://github.com/rust-lang/regex/pull/275):
  698. Improves match verification performance in the Teddy SIMD searcher.
  699. * [PR #278](https://github.com/rust-lang/regex/pull/278):
  700. Replaces slow substring loop in the Teddy SIMD searcher with Aho-Corasick.
  701. * Implemented DoubleEndedIterator on regex set match iterators.
  702. 0.1.74
  703. ======
  704. * Release regex-syntax 0.3.5 with a minor bug fix.
  705. * Fix bug #272.
  706. * Fix bug #277.
  707. * [PR #270](https://github.com/rust-lang/regex/pull/270):
  708. Fixes bugs #264, #268 and an unreported where the DFA cache size could be
  709. drastically under estimated in some cases (leading to high unexpected memory
  710. usage).
  711. 0.1.73
  712. ======
  713. * Release `regex-syntax 0.3.4`.
  714. * Bump `regex-syntax` dependency version for `regex` to `0.3.4`.
  715. 0.1.72
  716. ======
  717. * [PR #262](https://github.com/rust-lang/regex/pull/262):
  718. Fixes a number of small bugs caught by fuzz testing (AFL).
  719. 0.1.71
  720. ======
  721. * [PR #236](https://github.com/rust-lang/regex/pull/236):
  722. Fix a bug in how suffix literals were extracted, which could lead
  723. to invalid match behavior in some cases.
  724. 0.1.70
  725. ======
  726. * [PR #231](https://github.com/rust-lang/regex/pull/231):
  727. Add SIMD accelerated multiple pattern search.
  728. * [PR #228](https://github.com/rust-lang/regex/pull/228):
  729. Reintroduce the reverse suffix literal optimization.
  730. * [PR #226](https://github.com/rust-lang/regex/pull/226):
  731. Implements NFA state compression in the lazy DFA.
  732. * [PR #223](https://github.com/rust-lang/regex/pull/223):
  733. A fully anchored RegexSet can now short-circuit.
  734. 0.1.69
  735. ======
  736. * [PR #216](https://github.com/rust-lang/regex/pull/216):
  737. Tweak the threshold for running backtracking.
  738. * [PR #217](https://github.com/rust-lang/regex/pull/217):
  739. Add upper limit (from the DFA) to capture search (for the NFA).
  740. * [PR #218](https://github.com/rust-lang/regex/pull/218):
  741. Add rure, a C API.
  742. 0.1.68
  743. ======
  744. * [PR #210](https://github.com/rust-lang/regex/pull/210):
  745. Fixed a performance bug in `bytes::Regex::replace` where `extend` was used
  746. instead of `extend_from_slice`.
  747. * [PR #211](https://github.com/rust-lang/regex/pull/211):
  748. Fixed a bug in the handling of word boundaries in the DFA.
  749. * [PR #213](https://github.com/rust-lang/pull/213):
  750. Added RE2 and Tcl to the benchmark harness. Also added a CLI utility from
  751. running regexes using any of the following regex engines: PCRE1, PCRE2,
  752. Oniguruma, RE2, Tcl and of course Rust's own regexes.
  753. 0.1.67
  754. ======
  755. * [PR #201](https://github.com/rust-lang/regex/pull/201):
  756. Fix undefined behavior in the `regex!` compiler plugin macro.
  757. * [PR #205](https://github.com/rust-lang/regex/pull/205):
  758. More improvements to DFA performance. Competitive with RE2. See PR for
  759. benchmarks.
  760. * [PR #209](https://github.com/rust-lang/regex/pull/209):
  761. Release 0.1.66 was semver incompatible since it required a newer version
  762. of Rust than previous releases. This PR fixes that. (And `0.1.66` was
  763. yanked.)
  764. 0.1.66
  765. ======
  766. * Speculative support for Unicode word boundaries was added to the DFA. This
  767. should remove the last common case that disqualified use of the DFA.
  768. * An optimization that scanned for suffix literals and then matched the regular
  769. expression in reverse was removed because it had worst case quadratic time
  770. complexity. It was replaced with a more limited optimization where, given any
  771. regex of the form `re$`, it will be matched in reverse from the end of the
  772. haystack.
  773. * [PR #202](https://github.com/rust-lang/regex/pull/202):
  774. The inner loop of the DFA was heavily optimized to improve cache locality
  775. and reduce the overall number of instructions run on each iteration. This
  776. represents the first use of `unsafe` in `regex` (to elide bounds checks).
  777. * [PR #200](https://github.com/rust-lang/regex/pull/200):
  778. Use of the `mempool` crate (which used thread local storage) was replaced
  779. with a faster version of a similar API in @Amanieu's `thread_local` crate.
  780. It should reduce contention when using a regex from multiple threads
  781. simultaneously.
  782. * PCRE2 JIT benchmarks were added. A benchmark comparison can be found
  783. [here](https://gist.github.com/anonymous/14683c01993e91689f7206a18675901b).
  784. (Includes a comparison with PCRE1's JIT and Oniguruma.)
  785. * A bug where word boundaries weren't being matched correctly in the DFA was
  786. fixed. This only affected use of `bytes::Regex`.
  787. * [#160](https://github.com/rust-lang/regex/issues/160):
  788. `Captures` now has a `Debug` impl.