1 2005-06-14 Raja R Harinath <harinath@gmail.com>
4 * Match.cs (Match) [zero-argument variant]: Make private.
5 * GroupCollection (Item) [string variant]: Don't look for the
6 group number in an empty match.
8 2005-06-10 Raja R Harinath <rharinath@novell.com>
10 * interpreter.cs (Interpreter.GenerateMatch): Avoid allocating two
11 intermediate arrays to build the final result.
12 (Interpreter.GetGroupInfo, Interpreter.PopulateGroup): New helper
14 * CaptureCollection.cs (list): Change from ArrayList to list.
15 (SetValue): New internal helper, used by Interpreter.PopulateGroup.
16 (Enumerator): Remove helper class.
17 (IEnumerator.GetEnumerator): Just use list.GetEnumerator.
18 * GroupCollection.cs: Likewise.
19 * Group.cs (Group): Move responsibility of populating 'Captures'
20 to Interpreter.PopulateGroup.
21 * Match.cs (Match): Move responsibility of populating 'Groups' to
22 Interpreter.GenerateMatch.
24 2005-05-25 Raja R Harinath <rharinath@novell.com>
26 * replace.cs (ReplacementEvaluator.Compile): Rewrite to avoid
27 creating several intermediate strings. Simplify internal
28 intermediate representation.
29 (ReplacementEvaluator.EvaluateAppend): New. Version of Evaluate
30 that builds the result directly on a passed-in StringBuilder.
31 (ReplacementEvaluator.Evaluate): Just a wrapper around
33 * regex.cs (MatchAppendEvaluator): New internal delegate.
34 (Regex.Replace): Use MatchAppendEvaluator.
35 (Regex.Adapter): New class used to adapt a MatchEvaluator to a
38 2005-05-24 Raja R Harinath <rharinath@novell.com>
40 * replace.cs (ReplacementEvaluator.CompileTerm): Fix group
43 2005-05-20 Ben Maurer <bmaurer@ximian.com>
45 * regex.cs: Some memory allocation optimizations.
47 2005-05-20 Raja R Harinath <rharinath@novell.com>
50 * replace.cs (ReplacementEvaluator.Compile): Allow CompileTerm to
51 fail and yet have advanced the pointer. Append the scanned-over
52 portion to the "literal" being built.
53 (ReplacementEvaluator.CompileTerm): Don't throw any exceptions.
54 If a term cannot be recognized, just return null.
56 * compiler.cs (InterpreterFactory.GroupCount): Fix. The 0'th
57 index corresponds to Opcode.Info.
59 * parser.cs (Parser.Unescape): If the string doesn't contain any
60 '\' character, don't allocate a new string.
62 * replace.cs (ReplacementEvalutator.Term.AppendResult): Rename
63 from GetResult. Append to a passed-in StringBuilder rather than
65 (ReplacementEvaluator.Evaluate): Update.
67 * Capture.cs, Group.cs, Match.cs: New files split out of ...
68 * match.cs: ... this. Remove.
70 2005-02-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
72 * parser.cs: stuff inside {} might not be a quantifier. Fixes
75 2005-01-10 Gonzalo Paniagua Javier <gonzalo@ximian.com>
77 * quicksearch.cs: handle IgnoreCase when getting the shift distance.
78 Fixes bug #69065. Patch by mei@work.email.ne.jp.
80 2005-01-08 Miguel de Icaza <miguel@ximian.com>
82 * syntax.cs: Applied patch from mei@work.email.ne.jp to fix bug
85 * parser.cs: Turns out that \digit sequences are octal sequences
86 (no leading zero is needed); And the three octal digit rule
87 applies to the leading zero as well.
89 This fixes the Unescape method.
91 2004-11-29 Gonzalo Paniagua Javier <gonzalo@ximian.com>
93 * regex.cs: use NextMatch to move on to the next match. Fixes bug
96 2004-11-09 Atsushi Enomoto <atsushi@ximian.com>
100 2004-11-08 Ben Maurer <bmaurer@ximian.com>
102 * replace.cs, parser.cs: Use stringbuilder for allocation sanity.
104 2004-10-21 Joerg Rosenkranz <joergr@voelcker.com>
106 * regex.cs: Fixed a bug introduced with the last patch which
107 prevented any replacements when a postive count is given.
108 This also happens in all overloads without count parameter.
110 2004-10-18 Gonzalo Paniagua Javier <gonzalo@ximian.com>
112 * regex.cs: in Replace, when count is negative, replacement continues
113 to the end of the string.
115 Fixes bug #68398. Patch by Jon Larimer.
117 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
119 * RegexRunner.cs: fixed case mismatch of methods
121 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
123 * RegexRunner.cs: marked TODO, added missing protected internal
124 fields, throw NotImplementedException in all methods
126 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
128 * RegexRunnerFactory.cs: removed comment, no longer throw exception
130 * regex.cs: fixed public API signature by renaming protected
131 internal fields and adding destructor, added MonoTODO attribute to
132 fields and method that are not yet implemented, changed not
133 implemented methods to throw NotImplementedException instead of
134 Exception, fixed names of field that are serialized
136 2004-06-06 Jambunathan K <kjambunathan@novell.com>
138 * parser.cs: Fixed issues with Regex.Unescape() identified as part of
139 debugging bug #58256. The original problem reported was about
140 inconsistency between the way we treat replacement patterns and the
141 way microsoft treats the replacement patterns in Regex.Replace(). MS
142 implementation is buggy and doesn't honour escape sequences in the
143 replacement patterns, even though the SDK claims otherwise.
146 2004-06-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
148 * syntax.cs: re-applied my patch from 2004-05-27 plus a fix which is
149 emitting a Category.All if both a category and its negated value are
152 2004-06-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
154 * syntax.cs: reverting my previous patch. It causes bigger problems.
156 2004-05-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
158 * category.cs: added LastValue field to mark the end of enum Category.
159 * syntax.cs: in CharacterClass, use Category.LastValue to get the size
160 of the array needed. Use a BitArray instead of bool[].
161 In AddCategory(), don't set the opposite category as false. Fixes
162 bug #59150. All tests pass.
164 2004-05-25 Jackson Harper <jackson@ximian.com>
166 * parser.cs: Allow creating a regular expression using {,n} as the
167 specified. The min bounds is set to -1, I am not completely sure
168 if that is what it is supposed to be but MS does not set it to 0
169 based on testing. Patch by dave-gnome-bugs@earth.li. Fixes bug #56761.
171 2004-05-12 Dick Porter <dick@ximian.com>
175 * RegexRunnerFactory.cs:
176 * RegexRunner.cs: More public API difference fixes.
178 * GroupCollection.cs:
179 * MatchCollection.cs:
180 * CaptureCollection.cs: Moved GroupCollection, MatchCollection and
181 CaptureCollection so that they no longer inherit from the
182 non-standard RegexCollectionBase class. Fixes the API difference.
184 2004-04-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
191 Patch by Eric Durand Tremblay.
192 1) Capture inner group when named.
193 2) Resolved parse error caused by not capturing inner group
194 3) Resolved incorrect capture group
195 4) Now, not capturing anything when unnamed ( correct behavior)
198 2004-04-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
204 * syntax.cs: converted to unix line endings.
206 2004-03-30 Lluis Sanchez Gual <lluis@ximian.com>
208 * collections.cs: In the indexer, return an empty group if the requested
210 * match.cs: Added default constructor for Group.
212 2004-03-24 Gonzalo Paniagua Javier <gonzalo@ximian.com>
214 * parser.cs: fixed group numbering.
216 2004-03-22 Jackson Harper <jackson@ximian.com>
218 * parser.cs: Use the group number as the name in mapping. Patch by
220 * regex.cs: Fix off by one error. Patch by Gert Driesen.
222 2004-03-17 Francois Beauchemin <beauche@softhome.net>
223 * syntax.cs, interpreter.cs, quicksearch.cs, regex.cs, compiler.cs :
224 Revised support for RigthToLeft.
225 quicksearch has now an reverse option.
226 This fixes bug #54537
228 * regex.cs, compiler.cs :
229 Some code to support CILCompiler.
231 Added some undocumented of MS.
233 2004-03-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
235 * parser.cs: allow a @"\0" escape sequence. Fixes bug #54797.
237 2004-02-01 Miguel de Icaza <miguel@ximian.com>
239 * syntax.cs, interval.cs: Applied patch from Marco Cravairo
240 through Francois Beauchemin who reviewed on the mailing list.
241 This fixes bug #45976
243 2004-01-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
245 * parser.cs: an opening brace without a
246 quantifier do not cause a parse error. Fixes bug #52924.
248 2004-01-07 Lluis Sanchez Gual <lluis@ximian.com>
250 * regex.cs: In Split(), if the last match is at the end of the string,
251 an empty string must be added to the array of results.
253 2003-12-15 Sanjay Gupta <gsanjay@novell.com>
254 * match.cs: Check for null value before Substring method call.
257 2003-11-21 Juraj Skripsky <js@hotfeet.ch>
259 * quicksearch.cs: Create and use hashtable only for "long" search
262 (Search): Use simple scan for a single-character search strings.
264 (GetChar): Simplify case sensitivity handling.
266 2003-11-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
268 * interpreter.cs: when evaluating a degenerate match, restore the
269 RepeatContext if fail. Fixes bug #42529.
271 2003-11-22 Jackson Harper <jackson@ximian.com>
273 * regex.cs: Add CultureInvariant flag to RegexOptions.
275 2003-11-20 Juraj Skripsky <js@hotfeet.ch>
277 * quicksearch.cs: Use a hashtable instead of an array for the
278 shift table to improve the memory usage.
280 2003-11-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
283 (Split): include capture groups in the results, if any. Fixes bug
286 2003-07-09 Gonzalo Paniagua Javier <gonzalo@ximian.com>
288 * regex.cs: patch from Eric Lindvall <eric@5stops.com> that fixes bug
291 2003-03-05 Miguel de Icaza <miguel@ximian.com>
293 * category.cs (CategoryUtils.CategoryFromName): Use StartsWith
294 ("Is") instead of a substring for (0,2) which was throwing an
295 exception causing Category.None to be returned
297 2003-01-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
299 * collections.cs: fixed bug #30091.
301 2002-12-20 Gonzalo Paniagua Javier <gonzalo@ximian.com>
303 * regex.cs: fixed little mistake (closes #35860).
305 2002-11-12 Jackson Harper <jackson@latitudegeo.com>
307 * arch.cs compiler.cs regex.cs: Added mapping attribute to MachineFactories
309 2002-11-06 Gonzalo Paniagua Javier <gonzalo@ximian.com>
311 * parser.cs: detect illegal \ at end of pattern. Fixes 31334.
313 2002-10-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
315 * parser.cs: applied fix from Tim Haynes (thaynes@openlinksw.com) to
316 solve bug #32807. Also modified GetMapping to return the same as MS.
318 2002-08-28 Juli Mallett <jmallett@FreeBSD.org>
320 * arch.cs, compiler.cs: Give the interpreter machine a property
321 for the retrieval of the group count.
323 * regex.cs: Use the new GroupCount property of the factory to
324 initialise the current group count, and restructure code to compile
325 the pattern only the first time it is needed (essentially backing
326 out the previous revision of regex.cs, to use the new code.)
328 2002-08-14 Cesar Octavio Lopez Nataren <cesar@ciencias.unam.mx>
330 * regex.cs: Added the ctr for ISerializable implementation and
331 implemented the GetObjectData function.
333 2002-07-30 Juli Mallett <jmallett@FreeBSD.org>
335 * regex.cs: Fixed bug where the expression would not be
336 re-evaluated for grouping purposes when factory caches were
337 used, resulting in no groups being recognised after one call
338 with a given pattern and no change in options.
340 2002-05-13 Dan Lewis <dihlewis@yahoo.co.uk>
342 * regex.cs: Fixed bug in split.
344 2002-05-08 Dan Lewis <dihlewis@yahoo.co.uk>
346 * interpreter.cs: Moved to an array-based stack representation
349 * match.cs, collections.cs: Decoupled capture representation from
350 interpreter internals.
352 * cache.cs: Changed Key type from struct to class for speed.
354 2002-04-06 Dan Lewis <dihlewis@yahoo.co.uk>
356 * cache.cs: Object methods should be overridden with "override".
358 2002-04-04 Dan Lewis <dihlewis@yahoo.co.uk>
360 * RegexRunner.cs, RegexRunnerFactory.cs: MS support classes. Stubs
361 added for completeness.
363 * regex.cs, match.cs, collections.cs: Serializable attribute.
365 2002-04-04 Dan Lewis <dihlewis@yahoo.co.uk>
367 * regex.cs: Added static Matches and IsMatch methods.
369 2002-04-03 Dan Lewis <dihlewis@yahoo.co.uk>
371 * ChangeLog: Added changelog.
373 * cache.cs: Fixed bug in MRUList.Evict.