1 2005-07-21 Florian Gross <flgr@ccan.de>
3 * Fixed a bug in category.cs that caused ECMAScript \d to fail.
5 2005-07-13 Raja R Harinath <rharinath@novell.com>
8 * MatchCollection.cs (TryToGet): Don't generate match i+1 when
9 we're looking for match i. Change post-conditions.
10 (FullList): New helper property. Ensures the list is fully populated.
11 (Count, CopyTo): Use it.
12 (Enumerator.Current): Update to new post-conditions of TryToGet.
13 (Enumerator.MoveNext): Likewise. Don't modify index if we're
16 2005-07-08 Raja R Harinath <rharinath@novell.com>
18 * MatchCollection.cs: Convert to incremental mode.
19 * regex.cs (Regex.Matches): Update. Pass responsibility of
20 generating all matches to MatchCollection.
22 2005-06-14 Raja R Harinath <harinath@gmail.com>
24 * parser.cs (Parser.ConsumeWhitespace): Add bounds check.
27 * Match.cs (Match) [zero-argument variant]: Make private.
28 * GroupCollection (Item) [string variant]: Don't look for the
29 group number in an empty match.
31 2005-06-10 Raja R Harinath <rharinath@novell.com>
33 * interpreter.cs (Interpreter.GenerateMatch): Avoid allocating two
34 intermediate arrays to build the final result.
35 (Interpreter.GetGroupInfo, Interpreter.PopulateGroup): New helper
37 * CaptureCollection.cs (list): Change from ArrayList to list.
38 (SetValue): New internal helper, used by Interpreter.PopulateGroup.
39 (Enumerator): Remove helper class.
40 (IEnumerator.GetEnumerator): Just use list.GetEnumerator.
41 * GroupCollection.cs: Likewise.
42 * Group.cs (Group): Move responsibility of populating 'Captures'
43 to Interpreter.PopulateGroup.
44 * Match.cs (Match): Move responsibility of populating 'Groups' to
45 Interpreter.GenerateMatch.
47 2005-05-25 Raja R Harinath <rharinath@novell.com>
49 * replace.cs (ReplacementEvaluator.Compile): Rewrite to avoid
50 creating several intermediate strings. Simplify internal
51 intermediate representation.
52 (ReplacementEvaluator.EvaluateAppend): New. Version of Evaluate
53 that builds the result directly on a passed-in StringBuilder.
54 (ReplacementEvaluator.Evaluate): Just a wrapper around
56 * regex.cs (MatchAppendEvaluator): New internal delegate.
57 (Regex.Replace): Use MatchAppendEvaluator.
58 (Regex.Adapter): New class used to adapt a MatchEvaluator to a
61 2005-05-24 Raja R Harinath <rharinath@novell.com>
63 * replace.cs (ReplacementEvaluator.CompileTerm): Fix group
66 2005-05-20 Ben Maurer <bmaurer@ximian.com>
68 * regex.cs: Some memory allocation optimizations.
70 2005-05-20 Raja R Harinath <rharinath@novell.com>
73 * replace.cs (ReplacementEvaluator.Compile): Allow CompileTerm to
74 fail and yet have advanced the pointer. Append the scanned-over
75 portion to the "literal" being built.
76 (ReplacementEvaluator.CompileTerm): Don't throw any exceptions.
77 If a term cannot be recognized, just return null.
79 * compiler.cs (InterpreterFactory.GroupCount): Fix. The 0'th
80 index corresponds to Opcode.Info.
82 * parser.cs (Parser.Unescape): If the string doesn't contain any
83 '\' character, don't allocate a new string.
85 * replace.cs (ReplacementEvalutator.Term.AppendResult): Rename
86 from GetResult. Append to a passed-in StringBuilder rather than
88 (ReplacementEvaluator.Evaluate): Update.
90 * Capture.cs, Group.cs, Match.cs: New files split out of ...
91 * match.cs: ... this. Remove.
93 2005-02-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
95 * parser.cs: stuff inside {} might not be a quantifier. Fixes
98 2005-01-10 Gonzalo Paniagua Javier <gonzalo@ximian.com>
100 * quicksearch.cs: handle IgnoreCase when getting the shift distance.
101 Fixes bug #69065. Patch by mei@work.email.ne.jp.
103 2005-01-08 Miguel de Icaza <miguel@ximian.com>
105 * syntax.cs: Applied patch from mei@work.email.ne.jp to fix bug
108 * parser.cs: Turns out that \digit sequences are octal sequences
109 (no leading zero is needed); And the three octal digit rule
110 applies to the leading zero as well.
112 This fixes the Unescape method.
114 2004-11-29 Gonzalo Paniagua Javier <gonzalo@ximian.com>
116 * regex.cs: use NextMatch to move on to the next match. Fixes bug
119 2004-11-09 Atsushi Enomoto <atsushi@ximian.com>
123 2004-11-08 Ben Maurer <bmaurer@ximian.com>
125 * replace.cs, parser.cs: Use stringbuilder for allocation sanity.
127 2004-10-21 Joerg Rosenkranz <joergr@voelcker.com>
129 * regex.cs: Fixed a bug introduced with the last patch which
130 prevented any replacements when a postive count is given.
131 This also happens in all overloads without count parameter.
133 2004-10-18 Gonzalo Paniagua Javier <gonzalo@ximian.com>
135 * regex.cs: in Replace, when count is negative, replacement continues
136 to the end of the string.
138 Fixes bug #68398. Patch by Jon Larimer.
140 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
142 * RegexRunner.cs: fixed case mismatch of methods
144 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
146 * RegexRunner.cs: marked TODO, added missing protected internal
147 fields, throw NotImplementedException in all methods
149 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
151 * RegexRunnerFactory.cs: removed comment, no longer throw exception
153 * regex.cs: fixed public API signature by renaming protected
154 internal fields and adding destructor, added MonoTODO attribute to
155 fields and method that are not yet implemented, changed not
156 implemented methods to throw NotImplementedException instead of
157 Exception, fixed names of field that are serialized
159 2004-06-06 Jambunathan K <kjambunathan@novell.com>
161 * parser.cs: Fixed issues with Regex.Unescape() identified as part of
162 debugging bug #58256. The original problem reported was about
163 inconsistency between the way we treat replacement patterns and the
164 way microsoft treats the replacement patterns in Regex.Replace(). MS
165 implementation is buggy and doesn't honour escape sequences in the
166 replacement patterns, even though the SDK claims otherwise.
169 2004-06-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
171 * syntax.cs: re-applied my patch from 2004-05-27 plus a fix which is
172 emitting a Category.All if both a category and its negated value are
175 2004-06-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
177 * syntax.cs: reverting my previous patch. It causes bigger problems.
179 2004-05-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
181 * category.cs: added LastValue field to mark the end of enum Category.
182 * syntax.cs: in CharacterClass, use Category.LastValue to get the size
183 of the array needed. Use a BitArray instead of bool[].
184 In AddCategory(), don't set the opposite category as false. Fixes
185 bug #59150. All tests pass.
187 2004-05-25 Jackson Harper <jackson@ximian.com>
189 * parser.cs: Allow creating a regular expression using {,n} as the
190 specified. The min bounds is set to -1, I am not completely sure
191 if that is what it is supposed to be but MS does not set it to 0
192 based on testing. Patch by dave-gnome-bugs@earth.li. Fixes bug #56761.
194 2004-05-12 Dick Porter <dick@ximian.com>
198 * RegexRunnerFactory.cs:
199 * RegexRunner.cs: More public API difference fixes.
201 * GroupCollection.cs:
202 * MatchCollection.cs:
203 * CaptureCollection.cs: Moved GroupCollection, MatchCollection and
204 CaptureCollection so that they no longer inherit from the
205 non-standard RegexCollectionBase class. Fixes the API difference.
207 2004-04-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
214 Patch by Eric Durand Tremblay.
215 1) Capture inner group when named.
216 2) Resolved parse error caused by not capturing inner group
217 3) Resolved incorrect capture group
218 4) Now, not capturing anything when unnamed ( correct behavior)
221 2004-04-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
227 * syntax.cs: converted to unix line endings.
229 2004-03-30 Lluis Sanchez Gual <lluis@ximian.com>
231 * collections.cs: In the indexer, return an empty group if the requested
233 * match.cs: Added default constructor for Group.
235 2004-03-24 Gonzalo Paniagua Javier <gonzalo@ximian.com>
237 * parser.cs: fixed group numbering.
239 2004-03-22 Jackson Harper <jackson@ximian.com>
241 * parser.cs: Use the group number as the name in mapping. Patch by
243 * regex.cs: Fix off by one error. Patch by Gert Driesen.
245 2004-03-17 Francois Beauchemin <beauche@softhome.net>
246 * syntax.cs, interpreter.cs, quicksearch.cs, regex.cs, compiler.cs :
247 Revised support for RigthToLeft.
248 quicksearch has now an reverse option.
249 This fixes bug #54537
251 * regex.cs, compiler.cs :
252 Some code to support CILCompiler.
254 Added some undocumented of MS.
256 2004-03-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
258 * parser.cs: allow a @"\0" escape sequence. Fixes bug #54797.
260 2004-02-01 Miguel de Icaza <miguel@ximian.com>
262 * syntax.cs, interval.cs: Applied patch from Marco Cravairo
263 through Francois Beauchemin who reviewed on the mailing list.
264 This fixes bug #45976
266 2004-01-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
268 * parser.cs: an opening brace without a
269 quantifier do not cause a parse error. Fixes bug #52924.
271 2004-01-07 Lluis Sanchez Gual <lluis@ximian.com>
273 * regex.cs: In Split(), if the last match is at the end of the string,
274 an empty string must be added to the array of results.
276 2003-12-15 Sanjay Gupta <gsanjay@novell.com>
277 * match.cs: Check for null value before Substring method call.
280 2003-11-21 Juraj Skripsky <js@hotfeet.ch>
282 * quicksearch.cs: Create and use hashtable only for "long" search
285 (Search): Use simple scan for a single-character search strings.
287 (GetChar): Simplify case sensitivity handling.
289 2003-11-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
291 * interpreter.cs: when evaluating a degenerate match, restore the
292 RepeatContext if fail. Fixes bug #42529.
294 2003-11-22 Jackson Harper <jackson@ximian.com>
296 * regex.cs: Add CultureInvariant flag to RegexOptions.
298 2003-11-20 Juraj Skripsky <js@hotfeet.ch>
300 * quicksearch.cs: Use a hashtable instead of an array for the
301 shift table to improve the memory usage.
303 2003-11-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
306 (Split): include capture groups in the results, if any. Fixes bug
309 2003-07-09 Gonzalo Paniagua Javier <gonzalo@ximian.com>
311 * regex.cs: patch from Eric Lindvall <eric@5stops.com> that fixes bug
314 2003-03-05 Miguel de Icaza <miguel@ximian.com>
316 * category.cs (CategoryUtils.CategoryFromName): Use StartsWith
317 ("Is") instead of a substring for (0,2) which was throwing an
318 exception causing Category.None to be returned
320 2003-01-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
322 * collections.cs: fixed bug #30091.
324 2002-12-20 Gonzalo Paniagua Javier <gonzalo@ximian.com>
326 * regex.cs: fixed little mistake (closes #35860).
328 2002-11-12 Jackson Harper <jackson@latitudegeo.com>
330 * arch.cs compiler.cs regex.cs: Added mapping attribute to MachineFactories
332 2002-11-06 Gonzalo Paniagua Javier <gonzalo@ximian.com>
334 * parser.cs: detect illegal \ at end of pattern. Fixes 31334.
336 2002-10-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
338 * parser.cs: applied fix from Tim Haynes (thaynes@openlinksw.com) to
339 solve bug #32807. Also modified GetMapping to return the same as MS.
341 2002-08-28 Juli Mallett <jmallett@FreeBSD.org>
343 * arch.cs, compiler.cs: Give the interpreter machine a property
344 for the retrieval of the group count.
346 * regex.cs: Use the new GroupCount property of the factory to
347 initialise the current group count, and restructure code to compile
348 the pattern only the first time it is needed (essentially backing
349 out the previous revision of regex.cs, to use the new code.)
351 2002-08-14 Cesar Octavio Lopez Nataren <cesar@ciencias.unam.mx>
353 * regex.cs: Added the ctr for ISerializable implementation and
354 implemented the GetObjectData function.
356 2002-07-30 Juli Mallett <jmallett@FreeBSD.org>
358 * regex.cs: Fixed bug where the expression would not be
359 re-evaluated for grouping purposes when factory caches were
360 used, resulting in no groups being recognised after one call
361 with a given pattern and no change in options.
363 2002-05-13 Dan Lewis <dihlewis@yahoo.co.uk>
365 * regex.cs: Fixed bug in split.
367 2002-05-08 Dan Lewis <dihlewis@yahoo.co.uk>
369 * interpreter.cs: Moved to an array-based stack representation
372 * match.cs, collections.cs: Decoupled capture representation from
373 interpreter internals.
375 * cache.cs: Changed Key type from struct to class for speed.
377 2002-04-06 Dan Lewis <dihlewis@yahoo.co.uk>
379 * cache.cs: Object methods should be overridden with "override".
381 2002-04-04 Dan Lewis <dihlewis@yahoo.co.uk>
383 * RegexRunner.cs, RegexRunnerFactory.cs: MS support classes. Stubs
384 added for completeness.
386 * regex.cs, match.cs, collections.cs: Serializable attribute.
388 2002-04-04 Dan Lewis <dihlewis@yahoo.co.uk>
390 * regex.cs: Added static Matches and IsMatch methods.
392 2002-04-03 Dan Lewis <dihlewis@yahoo.co.uk>
394 * ChangeLog: Added changelog.
396 * cache.cs: Fixed bug in MRUList.Evict.