1 2009-04-23 Sebastien Pouliot <sebastien@ximian.com>
3 * Regex.cs: Remove Compiler-related support for NET_2_1
4 * RegexOptions.cs: Remove Compile from values available on NET_2_1
6 2009-03-04 Zoltan Varga <vargaz@gmail.com>
8 * RxInterpreter.cs (ResetGroups): Avoid allocating larger than needed
11 2009-02-27 Jonathan Pryor <jpryor@novell.com>
13 * Regex.cs (Replace): Check that input & evaluator are not null, as
14 documented in MSDN (and the variance found while testing DbLinq).
16 2009-02-27 Zoltan Varga <vargaz@gmail.com>
18 * BaseMachine.cs (LTRReplace): Initialize the StringBuilder with an
19 appropriate initial length.
21 2009-02-24 Zoltan Varga <vargaz@gmail.com>
23 * CILCompiler.cs: Partially inline calls to Char.ToLower () to speed
24 up ignorecase matching.
26 2009-02-16 Jb Evain <jbevain@novell.com>
28 * Regex.cs: on the NET_2_1 profile, always use the old engine for now.
30 2009-02-14 Zoltan Varga <vargaz@gmail.com>
32 * Regex.cs: Add a MONO_NEW_RX variable to enable the new regex
35 2009-02-04 Zoltan Varga <vargaz@gmail.com>
37 * Regex.cs: Disable the new regex engine for now.
39 2009-01-14 Zoltan Varga <vargaz@gmail.com>
41 * CILCompiler.cs: Avoid throwing exceptions for a few more unhandled opcodes.
42 Implement the reverse/ignorecase versions of Reference. Fix the reverse
43 version of Bitmap. Error out if a Jump opcode jumps outside the current
44 pc range. This works around #466151.
46 2009-01-12 Jb Evain <jbevain@novell.com>
48 * RxInterpreter.cs: set trace_rx to false for NET_2_1.
49 * Regex.cs: set old_rx to false for NET_2_1.
51 2009-01-07 Zoltan Varga <vargaz@gmail.com>
53 * RxInterpreter.cs: Add support for constant strings in anchors. Fixes
56 2008-11-18 Gonzalo Paniagua Javier <gonzalo@novell.com>
58 * cache.cs: avoid infinite loop.
60 2008-11-14 Gonzalo Paniagua Javier <gonzalo@novell.com>
63 * Regex.cs: honor CacheSize value.
65 2008-11-13 Zoltan Varga <vargaz@gmail.com>
67 * RxInterpreter.cs: Fix pc computation in various opcodes. Fixes #443841.
69 2008-11-11 Zoltan Varga <vargaz@gmail.com>
71 * CILCompiler.cs: Implement Reference opcode.
73 2008-10-30 Zoltan Varga <vargaz@gmail.com>
75 * CILCompiler.cs: Implement SubExpression opcode.
77 * CILCompiler.cs: Save and restore strpos in the Test opcode. Fixes
80 2008-10-25 Zoltan Varga <vargaz@gmail.com>
82 * CILCompiler.cs: Implement Test opcode.
84 2008-10-25 Gonzalo Paniagua Javier <gonzalo@novell.com>
86 * RxInterpreter.cs: implement missing Unicode* opcodes and
87 StringReverseIgnoreCase.
89 2008-10-25 Zoltan Varga <vargaz@gmail.com>
91 * RxOp.cs: Remove unused Generic opcodes.
93 * RxCompiler.cs: Emit opcodes with flags using methods which can be
94 overriden by CILCompiler.cs, so we only have to override a few methods.
96 * CILCompiler.cs: Simplify based on the RxCompiler changes. Implement
97 UnicodeString opcode. Throw a NotImplementedException when an unsupported
98 opcode is encountered, since the IL compiler is now believed to be feature
101 2008-10-24 Zoltan Varga <vargaz@gmail.com>
103 * RxInterpreter.cs CILCompiler.cs gen-interp.cs: Fix the reading of short
104 values from the instruction stream.
106 * RxOp.cs: Add some missing unicode opcodes.
108 * gen-interp.cs RxInterpreter.cs: Generate Bitmap/UnicodeBitmap opcodes too.
110 * CILCompiler.cs (EmitEvalMethodBody): Add an 'end_pc' argument to mark the
111 end of the bytecode range which needs to be compiled. Use it to avoid
112 compiling the same bytecode multiple times in various opcodes. Fix
113 RxOp.Jump implementation. Add implementation for unicode opcodes.
115 2008-10-09 Zoltan Varga <vargaz@gmail.com>
117 * CILCompiler.cs: Implement NoBitmap/NoBitmapIgnoreCase. Fixes #432172.
119 2008-09-14 Zoltan Varga <vargaz@gmail.com>
121 * gen-interp.cs: New file to generate the all variants of the character
122 checking opcodes in RxInterpreter.cs.
124 * RxInterpreter.cs: Replace hand written code with code generated by
127 * RxInterpreter.cs: Fix the failure case of the No<XXX> opcodes. Fixes
130 2008-09-13 Zoltan Varga <vargaz@gmail.com>
132 * RxInterpreter.cs RxCompiler.cs: Implement some missing Category opcodes.
134 2008-09-07 Zoltan Varga <vargaz@gmail.com>
136 * CILCompiler.cs: Override ICompiler.EmitSet too so we set op_flags for
137 Bitmap opcodes too. Fixes #424073.
139 2008-09-06 Zoltan Varga <vargaz@gmail.com>
141 * Regex.cs: Make the new regex interpreter+compiler the default.
143 2008-08-31 Zoltan Varga <vargaz@gmail.com>
145 * RxInterpreter.cs: Port the Anchor+StartOfString optimization from the old
146 interpreter. Add credits.
148 * RxCompiler.cs (EmitString): Lowercase the string if ignore is true.
150 * CILCompiler.cs: Fix the setting of the match position in the
151 anchor+char optimization.
153 * CILCompiler.cs: Implement FastRepeatLazy.
155 * CILCompiler.cs: Get rid of commented out code. Also get rid of
156 frame.local_strpos_res, since the generated code already set Arg1 to
159 2008-08-30 Zoltan Varga <vargaz@gmail.com>
161 * CILCompiler.cs: Initialize all mi_ variables lazily.
163 * CILCompiler.cs: Implement FastRepeat.
165 * RxInterpreter.cs: Add back SetStartOfMatch, make it protected so as to
168 * CILCompiler.cs RxOp.cs: Merge lots of changes from RxInterpreter.cs,
171 2008-08-29 Zoltan Varga <vargaz@gmail.com>
173 * RxInterpreter.cs RxCompiler.cs RxOp.cs: Implement/fix this so all the
174 regex tests now run. The Repeat code is taken from the old interpreter.
176 2008-08-28 Zoltan Varga <vargaz@gmail.com>
178 * RxInterpreter.cs RxCompiler.cs RxOp.cs: Add support for
179 Category.AnySingleline.
181 2008-08-27 Zoltan Varga <vargaz@gmail.com>
183 * RxCompiler.cs: Use Array.Copy since Buffer.BlockCopy operates on bytes.
185 2008-07-31 Jb Evain <jbevain@novell.com>
187 * BaseMachine.cs: clean up for NET_2_1.
189 2008-06-05 Roei Erez <roeie@mainsoft.com>
191 * JvmReMachine.jvm.cs: Fix a bug in match that contains
192 empty group at the end.
194 2008-04-13 Jb Evain <jbevain@novell.com>
196 * Regex.cs: update undocumented fields for the 2.1 profile.
197 Merged from the Moonlight 2 branch.
199 2008-02-26 Zoltan Varga <vargaz@gmail.com>
201 * CILCompiler.cs: Implement StringIgnoreCase.
203 * CILCompiler.cs: Implement grouping support.
205 * CILCompiler.cs: Implement character groups.
207 2008-02-25 Zoltan Varga <vargaz@gmail.com>
209 * CILCompiler.cs: Implement lots of missing opcodes.
211 2008-02-18 Zoltan Varga <vargaz@gmail.com>
213 * CILCompiler.cs (EmitEvalMethodBody): Check for the not-yet supported
216 Thu Feb 14 19:03:00 CET 2008 Paolo Molaro <lupus@ximian.com>
218 * RxCompiler.cs, RxInterpreter.cs, RxOp.cs, CILCompiler.cs : support for word
219 boundary position opcodes, ignorecase backreference and more capture
222 Thu Feb 14 17:11:10 CET 2008 Paolo Molaro <lupus@ximian.com>
224 * RxCompiler.cs, RxInterpreter.cs, RxOp.cs: replace EcmaDigit with
225 Range, fixed matching of "" =~ /$/, implementedt TestCharGroup.
226 Fixes and other misc opcodes implemented.
228 2008-02-13 Zoltan Varga <vargaz@gmail.com>
230 * CILCompiler.cs: Restructure some code to avoid a branch inside a loop.
232 * CILCompiler.cs: Fix the unsafe string matching code.
234 * CILCompiler.cs: Improved version which emits only one method in most cases.
236 * CILCompiler.cs: Fix some comments.
238 * CILCompiler.cs: New file, extracted from RxCompiler.cs.
240 * RxInterpreter.cs RxCompiler.cs: First version of regex IL compiler.
242 Wed Feb 13 13:18:12 CET 2008 Paolo Molaro <lupus@ximian.com>
244 * RxCompiler.cs, RxInterpreter.cs, RxOp.cs: unicode categories and
245 some grouping/capture support.
247 Tue Feb 12 19:16:49 CET 2008 Paolo Molaro <lupus@ximian.com>
249 * RxCompiler.cs, RxInterpreter.cs, RxOp.cs: experimental new
252 2008-02-10 Zoltan Varga <vargaz@gmail.com>
254 * replace.cs (NeedsGroupsOrCaptures): New property. Determines whenever the
255 replacement process needs access to the groups or captures properties of the
258 * Group.cs: Add an internal ctor which avoids allocations.
262 * BaseMachine.cs interpreter.cs: Add an optimization to avoid fully creating
263 Match objects during Replace () if the replacement string is simple.
265 * BaseMachine.cs Regex.cs: Make LTRReplace and RTLReplace instance methods to
266 avoid creating two machines for each Regex.Replace () call.
268 * interpreter.cs (Eval): Remove a needless string allocation.
270 2007-12-04 Arina Itkes <arinai@mainsoft.com>
272 * parser.cs: Max value of m for a construct {n,m} is 2147483647.
274 2007-11-15 Miguel de Icaza <miguel@novell.com>
276 * Revert the patch from Juraj Skripsky as it made the class
277 non-thread safe (see #341986).
279 2007-11-08 Raja R Harinath <harinath@gmail.com>
282 * BaseMachine.cs (LTRReplace): Don't use non-advancement of 'ptr'
283 to deduce absence of matches -- a match can have length 0.
284 (RTLReplace): Likewise.
286 2007-11-07 Raja R Harinath <harinath@gmail.com>
288 Support RegexOptions.RightToLeft in Replace().
289 * BaseMachine.cs (Replace): Use either LTRReplace or RTLReplace
291 (LTRReplace): Make internal and rename the MatchAppendEvaluator
292 version of Replace to this.
294 * Regex.cs (Replace): Use LTRReplace and RTLReplace from BaseMachine.
295 * replace.cs (ReplacementEvaluator.Evaluate): Optimize simple case.
296 Based on patch by Stephane Delcroix.
298 * replace.cs (Compile): Don't unescape string.
300 2007-11-01 Gert Driesen <drieseng@users.sourceforge.net>
302 * Match.cs: Do not throw NotSupportedException on zero-length
303 replacement argument.
305 2007-10-29 Arina Itkes <arinai@mainsoft.com>
307 * Regex.cs: Moving creation of Regex machine to ctor.
308 It increases an initialization time of Regex but reduce a
309 process time while APIs calling. Also it solves the problem
310 of missed multi thread synchronization.
312 2007-10-29 Arina Itkes <arinai@mainsoft.com>
314 * Match.cs: Fix for Result method of Match. Throwing an exception
315 if Result method was called on a failed Match.
317 2007-10-24 Juraj Skripsky <js@hotfeet.ch>
319 * Regex.cs: Store and re-use IMachine, no need to re-instantiate
320 it every time we're matching.
322 2007-10-24 Arina Itkes <arinai@mainsoft.com>
324 * Regex.cs Match.cs arch.cs compiler.cs interpreter.cs
325 Refactoring of Interpreter with extracting of base abstract class
326 that executes some methods that were moved from Regex and Match classes.
327 Added a field that maps group numbers to group names in Regex for
328 improvement of performance of GroupNameFromNumber method.
330 2007-10-21 Gert Driesen <drieseng@users.sourceforge.net>
332 * RegexTest.cs: Removed. Test was already moved to the appropriate
335 2007-06-21 Juraj Skripsky <js@hotfeet.ch>
337 * quicksearch.ch: Optimization. Add byte array as skip table for
338 chars <= 255, falling back to the hashtable for chars > 255 and
339 skip distances > 255.
341 2007-04-18 Raja R Harinath <rharinath@novell.com>
344 * parser.cs (ResolveReferences): Don't throw an expression if a
345 capture assertion reference cannot be resolved.
346 (ParseGroupingConstruct): Provide fallback expression to a capture
348 * syntax.cs (CaptureAssertion): If the bareword doesn't refer to
349 the name of a capture group, fallback to treating it as a literal
352 2007-04-04 Raja R Harinath <rharinath@novell.com>
354 * interpreter.cs (Eval) <OpCode.Reference>: Distribute for loop
356 for () if (a) s1; else s2; => if (a) for () s1; else for () s2;
358 2007-04-03 Raja R Harinath <rharinath@novell.com>
360 * Regex.cs (~Regex): Don't define in NET_2_0 profile.
362 2007-01-02 Raja R Harinath <rharinath@novell.com>
365 * parser.cs (Parser.GetMapping): Use the actual group numbers to
368 2006-09-28 Andrew Skiba <andrews@mainsoft.com>
370 * Regex.cs: TARGET_JVM
372 2006-05-30 Gert Driesen <drieseng@users.sourceforge.net>
374 * CaptureCollection.cs: Removed virtual keyword to fix API mismatches.
375 * MatchCollection.cs: Removed virtual keyword to fix API mismatches.
376 * GroupCollection.cs: Removed virtual keyword to fix API mismatches.
378 2006-05-08 Raja R Harinath <rharinath@novell.com>
381 Remove 65535-limit on number of repetitions matched by a pattern.
382 We still have a 65535 limit on the length of a pattern and the
383 number of groups in a pattern.
384 * compiler.cs (PatternCompiler.EmitCount): New. Emits an int as
385 two ushorts into the program stream.
386 (EmitInfo, EmitRepeat, EmitFastRepeat): Use it to emit integers
388 * interpreter.cs (Intepreter.ReadProgramCount): Read an int
389 emitted into the program stream.
390 (Interpreter): Use it. Update counts.
391 (Interpreter.Eval) [OpCode.Repeat, OpCode.FastRepeat]: Likewise.
392 * parser.cs (ParseGroup): Pass 0x7ffffff as the max value for '*'
393 and '+' repetition patterns.
394 * arch.cs (Info, Repeat, FastRepeat): Update description.
396 2006-04-18 Raja R Harinath <rharinath@novell.com>
398 Treat fixed repetitions of simple regexes as simple too.
399 * syntax.cs (Expression.IsComplex): Make abstract.
400 (Group.IsComplex, Alternation.IsComplex): Move ...
401 (CompositeExpression.IsComplex): ... here.
402 (Group.GetAnchorInfo): Reduce allocations. Avoid creating another
403 ArrayList, and use a StringBuilder to build up the string.
404 (Repetition.GetAnchorInfo): Use a StringBuilder to build up the string.
405 (ExpressionAssertion.IsComplex): Override.
407 2006-04-17 Florian Gross <flgr@ccan.de>
408 Raja R Harinath <rharinath@novell.com>
410 * syntax.cs (CharacterClass.Compile): Emit categories after the
411 character intervals so that the evaluator can pick up the
414 2006-04-07 Raja R Harinath <rharinath@novell.com>
417 * interpreter.cs (Interpreter.Eval) [Anchor, Position.StartOfString]:
418 Don't reset 'ptr' to 0 during forward scan.
421 * interpreter.cs (Interpreter.FastEval) [FastRepeat]: If the first
422 tail operation has a 'negate' flag, avoid the "match next char"
426 * arch.cs (OpCode.NotCategory): New. Stands for matching a
427 character _not_ from the given category.
428 * debug.cs (DisassembleBlock): Handle it.
429 * compiler.cs (ICompiler.EmitNotCategory): New.
430 (Compiler.EmitNotCategory): New. Emit OpCode.NotCategory.
431 * syntax.cs (CharacterClass.Compile): Don't conflate negation of
432 the character class and negation of the category. Use
434 * interpreter.cs (Interpreter.Eval): Pass OpCode.NotCategory to
436 (Interpreter.EvalChar): Handle it.
438 2006-04-06 Raja R Harinath <rharinath@novell.com>
441 * interpreter.cs (Eval) [Until, FastUntil]: Set 'deep' to null
442 when evaluating the tail. Ensure that backtracks don't confuse
443 the recursion vs. iteration detector.
445 2006-04-03 Raja R Harinath <rharinath@novell.com>
447 * interpreter.cs (Eval) [Until, lazy]: Avoid extra evaluation on a
450 2006-03-30 Raja R Harinath <harinath@gmail.com>
453 * parser.cs (Parser.ParseCharacterClass): Don't automatically
454 assume there's a range when we see '-'. Ensure that we have seen
455 at least one other character, and that we aren't already parsing a
456 range. Handle some more errors.
458 2005-12-19 Kornél Pál <kornelpal@hotmail.com>
460 * Regex.cs: Added support for regular expressions compiled to
461 assemblies by compiling the pattern. This solution ignores existing
462 CIL code but provides full support for regular expression classes
465 2005-11-21 Sebastien Pouliot <sebastien@ximian.com>
467 * CaptureCollection.cs: Fixed length check.
468 * Group.cs: Added missing validation for Synchronized method.
469 * Match.cs: Added missing validation for Synchronized and Result
471 * MatchEvaluator.cs: Added [Serializable] for 2.0 profile.
472 * RegexCompilationInfo.cs: Added missing property validation.
473 * Regex.cs: Implemented UseOptionC and UseOptionR protected methods
474 (now documented). Fixed API for 2.0 profile.
475 * RegexRunner.cs: Stubbed CharInClass for 2.0 profile.
477 2005-11-17 Sebastien Pouliot <sebastien@ximian.com>
479 * Match.cs: Removed the ": base ()" on the private ctor as it is
480 unrequired and cause an extra public ctor to added (bug #76736).
481 * MatchCollection.cs: Add missing virtual to indexer property.
483 2005-09-23 Raja R Harinath <rharinath@novell.com>
485 * interpreter.cs (Interpreter.Eval) [OpCode.Until]: Invert the
486 sense of a test to reflect the code re-organization.
488 2005-09-22 Raja R Harinath <rharinath@novell.com>
491 * interpreter.cs (Interpreter.Eval) [OpCode.Until]: Avoid some
492 cases of recursion when dealing with eager quantifiers too. We
493 now avoid recursion when handling the innermost quantifier.
494 (Interpreter.IntStack, Interpreter.stack): New. Stack to help
495 implement backtracking in eager quantifiers.
497 2005-09-21 Raja R Harinath <rharinath@novell.com>
499 * interpreter.cs (Interpreter.Eval) [OpCode.Until]: Avoid some
500 cases of recursion when dealing with the minimum count and lazy
503 2005-08-23 Raja R Harinath <rharinath@novell.com>
505 * regex.cs: Remove. Split into ...
506 * MatchEvaluator.cs, Regex.cs, RegexCompilationInfo.cs,
507 RegexOptions.cs: ... these. Now every publicly exposed type in
508 this namespace has its own file.
510 2005-07-21 Florian Gross <flgr@ccan.de>
512 * Fixed a bug in category.cs that caused ECMAScript \d to fail.
514 2005-07-13 Raja R Harinath <rharinath@novell.com>
516 Make even more lazier.
517 * MatchCollection.cs (TryToGet): Don't generate match i+1 when
518 we're looking for match i. Change post-conditions.
519 (FullList): New helper property. Ensures the list is fully populated.
520 (Count, CopyTo): Use it.
521 (Enumerator.Current): Update to new post-conditions of TryToGet.
522 (Enumerator.MoveNext): Likewise. Don't modify index if we're
525 2005-07-08 Raja R Harinath <rharinath@novell.com>
527 * MatchCollection.cs: Convert to incremental mode.
528 * regex.cs (Regex.Matches): Update. Pass responsibility of
529 generating all matches to MatchCollection.
531 2005-06-14 Raja R Harinath <harinath@gmail.com>
533 * parser.cs (Parser.ConsumeWhitespace): Add bounds check.
536 * Match.cs (Match) [zero-argument variant]: Make private.
537 * GroupCollection (Item) [string variant]: Don't look for the
538 group number in an empty match.
540 2005-06-10 Raja R Harinath <rharinath@novell.com>
542 * interpreter.cs (Interpreter.GenerateMatch): Avoid allocating two
543 intermediate arrays to build the final result.
544 (Interpreter.GetGroupInfo, Interpreter.PopulateGroup): New helper
546 * CaptureCollection.cs (list): Change from ArrayList to list.
547 (SetValue): New internal helper, used by Interpreter.PopulateGroup.
548 (Enumerator): Remove helper class.
549 (IEnumerator.GetEnumerator): Just use list.GetEnumerator.
550 * GroupCollection.cs: Likewise.
551 * Group.cs (Group): Move responsibility of populating 'Captures'
552 to Interpreter.PopulateGroup.
553 * Match.cs (Match): Move responsibility of populating 'Groups' to
554 Interpreter.GenerateMatch.
556 2005-05-25 Raja R Harinath <rharinath@novell.com>
558 * replace.cs (ReplacementEvaluator.Compile): Rewrite to avoid
559 creating several intermediate strings. Simplify internal
560 intermediate representation.
561 (ReplacementEvaluator.EvaluateAppend): New. Version of Evaluate
562 that builds the result directly on a passed-in StringBuilder.
563 (ReplacementEvaluator.Evaluate): Just a wrapper around
565 * regex.cs (MatchAppendEvaluator): New internal delegate.
566 (Regex.Replace): Use MatchAppendEvaluator.
567 (Regex.Adapter): New class used to adapt a MatchEvaluator to a
568 MatchAppendEvaluator.
570 2005-05-24 Raja R Harinath <rharinath@novell.com>
572 * replace.cs (ReplacementEvaluator.CompileTerm): Fix group
575 2005-05-20 Ben Maurer <bmaurer@ximian.com>
577 * regex.cs: Some memory allocation optimizations.
579 2005-05-20 Raja R Harinath <rharinath@novell.com>
582 * replace.cs (ReplacementEvaluator.Compile): Allow CompileTerm to
583 fail and yet have advanced the pointer. Append the scanned-over
584 portion to the "literal" being built.
585 (ReplacementEvaluator.CompileTerm): Don't throw any exceptions.
586 If a term cannot be recognized, just return null.
588 * compiler.cs (InterpreterFactory.GroupCount): Fix. The 0'th
589 index corresponds to Opcode.Info.
591 * parser.cs (Parser.Unescape): If the string doesn't contain any
592 '\' character, don't allocate a new string.
594 * replace.cs (ReplacementEvalutator.Term.AppendResult): Rename
595 from GetResult. Append to a passed-in StringBuilder rather than
597 (ReplacementEvaluator.Evaluate): Update.
599 * Capture.cs, Group.cs, Match.cs: New files split out of ...
600 * match.cs: ... this. Remove.
602 2005-02-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
604 * parser.cs: stuff inside {} might not be a quantifier. Fixes
607 2005-01-10 Gonzalo Paniagua Javier <gonzalo@ximian.com>
609 * quicksearch.cs: handle IgnoreCase when getting the shift distance.
610 Fixes bug #69065. Patch by mei@work.email.ne.jp.
612 2005-01-08 Miguel de Icaza <miguel@ximian.com>
614 * syntax.cs: Applied patch from mei@work.email.ne.jp to fix bug
617 * parser.cs: Turns out that \digit sequences are octal sequences
618 (no leading zero is needed); And the three octal digit rule
619 applies to the leading zero as well.
621 This fixes the Unescape method.
623 2004-11-29 Gonzalo Paniagua Javier <gonzalo@ximian.com>
625 * regex.cs: use NextMatch to move on to the next match. Fixes bug
628 2004-11-09 Atsushi Enomoto <atsushi@ximian.com>
632 2004-11-08 Ben Maurer <bmaurer@ximian.com>
634 * replace.cs, parser.cs: Use stringbuilder for allocation sanity.
636 2004-10-21 Joerg Rosenkranz <joergr@voelcker.com>
638 * regex.cs: Fixed a bug introduced with the last patch which
639 prevented any replacements when a postive count is given.
640 This also happens in all overloads without count parameter.
642 2004-10-18 Gonzalo Paniagua Javier <gonzalo@ximian.com>
644 * regex.cs: in Replace, when count is negative, replacement continues
645 to the end of the string.
647 Fixes bug #68398. Patch by Jon Larimer.
649 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
651 * RegexRunner.cs: fixed case mismatch of methods
653 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
655 * RegexRunner.cs: marked TODO, added missing protected internal
656 fields, throw NotImplementedException in all methods
658 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
660 * RegexRunnerFactory.cs: removed comment, no longer throw exception
662 * regex.cs: fixed public API signature by renaming protected
663 internal fields and adding destructor, added MonoTODO attribute to
664 fields and method that are not yet implemented, changed not
665 implemented methods to throw NotImplementedException instead of
666 Exception, fixed names of field that are serialized
668 2004-06-06 Jambunathan K <kjambunathan@novell.com>
670 * parser.cs: Fixed issues with Regex.Unescape() identified as part of
671 debugging bug #58256. The original problem reported was about
672 inconsistency between the way we treat replacement patterns and the
673 way microsoft treats the replacement patterns in Regex.Replace(). MS
674 implementation is buggy and doesn't honour escape sequences in the
675 replacement patterns, even though the SDK claims otherwise.
678 2004-06-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
680 * syntax.cs: re-applied my patch from 2004-05-27 plus a fix which is
681 emitting a Category.All if both a category and its negated value are
684 2004-06-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
686 * syntax.cs: reverting my previous patch. It causes bigger problems.
688 2004-05-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
690 * category.cs: added LastValue field to mark the end of enum Category.
691 * syntax.cs: in CharacterClass, use Category.LastValue to get the size
692 of the array needed. Use a BitArray instead of bool[].
693 In AddCategory(), don't set the opposite category as false. Fixes
694 bug #59150. All tests pass.
696 2004-05-25 Jackson Harper <jackson@ximian.com>
698 * parser.cs: Allow creating a regular expression using {,n} as the
699 specified. The min bounds is set to -1, I am not completely sure
700 if that is what it is supposed to be but MS does not set it to 0
701 based on testing. Patch by dave-gnome-bugs@earth.li. Fixes bug #56761.
703 2004-05-12 Dick Porter <dick@ximian.com>
707 * RegexRunnerFactory.cs:
708 * RegexRunner.cs: More public API difference fixes.
710 * GroupCollection.cs:
711 * MatchCollection.cs:
712 * CaptureCollection.cs: Moved GroupCollection, MatchCollection and
713 CaptureCollection so that they no longer inherit from the
714 non-standard RegexCollectionBase class. Fixes the API difference.
716 2004-04-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
723 Patch by Eric Durand Tremblay.
724 1) Capture inner group when named.
725 2) Resolved parse error caused by not capturing inner group
726 3) Resolved incorrect capture group
727 4) Now, not capturing anything when unnamed ( correct behavior)
730 2004-04-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
736 * syntax.cs: converted to unix line endings.
738 2004-03-30 Lluis Sanchez Gual <lluis@ximian.com>
740 * collections.cs: In the indexer, return an empty group if the requested
742 * match.cs: Added default constructor for Group.
744 2004-03-24 Gonzalo Paniagua Javier <gonzalo@ximian.com>
746 * parser.cs: fixed group numbering.
748 2004-03-22 Jackson Harper <jackson@ximian.com>
750 * parser.cs: Use the group number as the name in mapping. Patch by
752 * regex.cs: Fix off by one error. Patch by Gert Driesen.
754 2004-03-17 Francois Beauchemin <beauche@softhome.net>
755 * syntax.cs, interpreter.cs, quicksearch.cs, regex.cs, compiler.cs :
756 Revised support for RigthToLeft.
757 quicksearch has now an reverse option.
758 This fixes bug #54537
760 * regex.cs, compiler.cs :
761 Some code to support CILCompiler.
763 Added some undocumented of MS.
765 2004-03-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
767 * parser.cs: allow a @"\0" escape sequence. Fixes bug #54797.
769 2004-02-01 Miguel de Icaza <miguel@ximian.com>
771 * syntax.cs, interval.cs: Applied patch from Marco Cravairo
772 through Francois Beauchemin who reviewed on the mailing list.
773 This fixes bug #45976
775 2004-01-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
777 * parser.cs: an opening brace without a
778 quantifier do not cause a parse error. Fixes bug #52924.
780 2004-01-07 Lluis Sanchez Gual <lluis@ximian.com>
782 * regex.cs: In Split(), if the last match is at the end of the string,
783 an empty string must be added to the array of results.
785 2003-12-15 Sanjay Gupta <gsanjay@novell.com>
786 * match.cs: Check for null value before Substring method call.
789 2003-11-21 Juraj Skripsky <js@hotfeet.ch>
791 * quicksearch.cs: Create and use hashtable only for "long" search
794 (Search): Use simple scan for a single-character search strings.
796 (GetChar): Simplify case sensitivity handling.
798 2003-11-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
800 * interpreter.cs: when evaluating a degenerate match, restore the
801 RepeatContext if fail. Fixes bug #42529.
803 2003-11-22 Jackson Harper <jackson@ximian.com>
805 * regex.cs: Add CultureInvariant flag to RegexOptions.
807 2003-11-20 Juraj Skripsky <js@hotfeet.ch>
809 * quicksearch.cs: Use a hashtable instead of an array for the
810 shift table to improve the memory usage.
812 2003-11-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
815 (Split): include capture groups in the results, if any. Fixes bug
818 2003-07-09 Gonzalo Paniagua Javier <gonzalo@ximian.com>
820 * regex.cs: patch from Eric Lindvall <eric@5stops.com> that fixes bug
823 2003-03-05 Miguel de Icaza <miguel@ximian.com>
825 * category.cs (CategoryUtils.CategoryFromName): Use StartsWith
826 ("Is") instead of a substring for (0,2) which was throwing an
827 exception causing Category.None to be returned
829 2003-01-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
831 * collections.cs: fixed bug #30091.
833 2002-12-20 Gonzalo Paniagua Javier <gonzalo@ximian.com>
835 * regex.cs: fixed little mistake (closes #35860).
837 2002-11-12 Jackson Harper <jackson@latitudegeo.com>
839 * arch.cs compiler.cs regex.cs: Added mapping attribute to MachineFactories
841 2002-11-06 Gonzalo Paniagua Javier <gonzalo@ximian.com>
843 * parser.cs: detect illegal \ at end of pattern. Fixes 31334.
845 2002-10-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
847 * parser.cs: applied fix from Tim Haynes (thaynes@openlinksw.com) to
848 solve bug #32807. Also modified GetMapping to return the same as MS.
850 2002-08-28 Juli Mallett <jmallett@FreeBSD.org>
852 * arch.cs, compiler.cs: Give the interpreter machine a property
853 for the retrieval of the group count.
855 * regex.cs: Use the new GroupCount property of the factory to
856 initialise the current group count, and restructure code to compile
857 the pattern only the first time it is needed (essentially backing
858 out the previous revision of regex.cs, to use the new code.)
860 2002-08-14 Cesar Octavio Lopez Nataren <cesar@ciencias.unam.mx>
862 * regex.cs: Added the ctr for ISerializable implementation and
863 implemented the GetObjectData function.
865 2002-07-30 Juli Mallett <jmallett@FreeBSD.org>
867 * regex.cs: Fixed bug where the expression would not be
868 re-evaluated for grouping purposes when factory caches were
869 used, resulting in no groups being recognised after one call
870 with a given pattern and no change in options.
872 2002-05-13 Dan Lewis <dihlewis@yahoo.co.uk>
874 * regex.cs: Fixed bug in split.
876 2002-05-08 Dan Lewis <dihlewis@yahoo.co.uk>
878 * interpreter.cs: Moved to an array-based stack representation
881 * match.cs, collections.cs: Decoupled capture representation from
882 interpreter internals.
884 * cache.cs: Changed Key type from struct to class for speed.
886 2002-04-06 Dan Lewis <dihlewis@yahoo.co.uk>
888 * cache.cs: Object methods should be overridden with "override".
890 2002-04-04 Dan Lewis <dihlewis@yahoo.co.uk>
892 * RegexRunner.cs, RegexRunnerFactory.cs: MS support classes. Stubs
893 added for completeness.
895 * regex.cs, match.cs, collections.cs: Serializable attribute.
897 2002-04-04 Dan Lewis <dihlewis@yahoo.co.uk>
899 * regex.cs: Added static Matches and IsMatch methods.
901 2002-04-03 Dan Lewis <dihlewis@yahoo.co.uk>
903 * ChangeLog: Added changelog.
905 * cache.cs: Fixed bug in MRUList.Evict.