1 2009-08-10 Raja R Harinath <harinath@hurrynot.org>
3 * syntax.cs (BackslashNumber): New class.
4 * parser.cs (ParseSpecial): Create it instead of 'Reference' if a
5 numeric backreference is seen.
7 2009-08-10 Raja R Harinath <harinath@hurrynot.org>
9 * parser.cs (ResolveReferences): Allow named groups to be
10 referred-to by their group numbers too.
12 2009-04-23 Sebastien Pouliot <sebastien@ximian.com>
14 * Regex.cs: Remove Compiler-related support for NET_2_1
15 * RegexOptions.cs: Remove Compile from values available on NET_2_1
17 2009-03-04 Zoltan Varga <vargaz@gmail.com>
19 * RxInterpreter.cs (ResetGroups): Avoid allocating larger than needed
22 2009-02-27 Jonathan Pryor <jpryor@novell.com>
24 * Regex.cs (Replace): Check that input & evaluator are not null, as
25 documented in MSDN (and the variance found while testing DbLinq).
27 2009-02-27 Zoltan Varga <vargaz@gmail.com>
29 * BaseMachine.cs (LTRReplace): Initialize the StringBuilder with an
30 appropriate initial length.
32 2009-02-24 Zoltan Varga <vargaz@gmail.com>
34 * CILCompiler.cs: Partially inline calls to Char.ToLower () to speed
35 up ignorecase matching.
37 2009-02-16 Jb Evain <jbevain@novell.com>
39 * Regex.cs: on the NET_2_1 profile, always use the old engine for now.
41 2009-02-14 Zoltan Varga <vargaz@gmail.com>
43 * Regex.cs: Add a MONO_NEW_RX variable to enable the new regex
46 2009-02-04 Zoltan Varga <vargaz@gmail.com>
48 * Regex.cs: Disable the new regex engine for now.
50 2009-01-14 Zoltan Varga <vargaz@gmail.com>
52 * CILCompiler.cs: Avoid throwing exceptions for a few more unhandled opcodes.
53 Implement the reverse/ignorecase versions of Reference. Fix the reverse
54 version of Bitmap. Error out if a Jump opcode jumps outside the current
55 pc range. This works around #466151.
57 2009-01-12 Jb Evain <jbevain@novell.com>
59 * RxInterpreter.cs: set trace_rx to false for NET_2_1.
60 * Regex.cs: set old_rx to false for NET_2_1.
62 2009-01-07 Zoltan Varga <vargaz@gmail.com>
64 * RxInterpreter.cs: Add support for constant strings in anchors. Fixes
67 2008-11-18 Gonzalo Paniagua Javier <gonzalo@novell.com>
69 * cache.cs: avoid infinite loop.
71 2008-11-14 Gonzalo Paniagua Javier <gonzalo@novell.com>
74 * Regex.cs: honor CacheSize value.
76 2008-11-13 Zoltan Varga <vargaz@gmail.com>
78 * RxInterpreter.cs: Fix pc computation in various opcodes. Fixes #443841.
80 2008-11-11 Zoltan Varga <vargaz@gmail.com>
82 * CILCompiler.cs: Implement Reference opcode.
84 2008-10-30 Zoltan Varga <vargaz@gmail.com>
86 * CILCompiler.cs: Implement SubExpression opcode.
88 * CILCompiler.cs: Save and restore strpos in the Test opcode. Fixes
91 2008-10-25 Zoltan Varga <vargaz@gmail.com>
93 * CILCompiler.cs: Implement Test opcode.
95 2008-10-25 Gonzalo Paniagua Javier <gonzalo@novell.com>
97 * RxInterpreter.cs: implement missing Unicode* opcodes and
98 StringReverseIgnoreCase.
100 2008-10-25 Zoltan Varga <vargaz@gmail.com>
102 * RxOp.cs: Remove unused Generic opcodes.
104 * RxCompiler.cs: Emit opcodes with flags using methods which can be
105 overriden by CILCompiler.cs, so we only have to override a few methods.
107 * CILCompiler.cs: Simplify based on the RxCompiler changes. Implement
108 UnicodeString opcode. Throw a NotImplementedException when an unsupported
109 opcode is encountered, since the IL compiler is now believed to be feature
112 2008-10-24 Zoltan Varga <vargaz@gmail.com>
114 * RxInterpreter.cs CILCompiler.cs gen-interp.cs: Fix the reading of short
115 values from the instruction stream.
117 * RxOp.cs: Add some missing unicode opcodes.
119 * gen-interp.cs RxInterpreter.cs: Generate Bitmap/UnicodeBitmap opcodes too.
121 * CILCompiler.cs (EmitEvalMethodBody): Add an 'end_pc' argument to mark the
122 end of the bytecode range which needs to be compiled. Use it to avoid
123 compiling the same bytecode multiple times in various opcodes. Fix
124 RxOp.Jump implementation. Add implementation for unicode opcodes.
126 2008-10-09 Zoltan Varga <vargaz@gmail.com>
128 * CILCompiler.cs: Implement NoBitmap/NoBitmapIgnoreCase. Fixes #432172.
130 2008-09-14 Zoltan Varga <vargaz@gmail.com>
132 * gen-interp.cs: New file to generate the all variants of the character
133 checking opcodes in RxInterpreter.cs.
135 * RxInterpreter.cs: Replace hand written code with code generated by
138 * RxInterpreter.cs: Fix the failure case of the No<XXX> opcodes. Fixes
141 2008-09-13 Zoltan Varga <vargaz@gmail.com>
143 * RxInterpreter.cs RxCompiler.cs: Implement some missing Category opcodes.
145 2008-09-07 Zoltan Varga <vargaz@gmail.com>
147 * CILCompiler.cs: Override ICompiler.EmitSet too so we set op_flags for
148 Bitmap opcodes too. Fixes #424073.
150 2008-09-06 Zoltan Varga <vargaz@gmail.com>
152 * Regex.cs: Make the new regex interpreter+compiler the default.
154 2008-08-31 Zoltan Varga <vargaz@gmail.com>
156 * RxInterpreter.cs: Port the Anchor+StartOfString optimization from the old
157 interpreter. Add credits.
159 * RxCompiler.cs (EmitString): Lowercase the string if ignore is true.
161 * CILCompiler.cs: Fix the setting of the match position in the
162 anchor+char optimization.
164 * CILCompiler.cs: Implement FastRepeatLazy.
166 * CILCompiler.cs: Get rid of commented out code. Also get rid of
167 frame.local_strpos_res, since the generated code already set Arg1 to
170 2008-08-30 Zoltan Varga <vargaz@gmail.com>
172 * CILCompiler.cs: Initialize all mi_ variables lazily.
174 * CILCompiler.cs: Implement FastRepeat.
176 * RxInterpreter.cs: Add back SetStartOfMatch, make it protected so as to
179 * CILCompiler.cs RxOp.cs: Merge lots of changes from RxInterpreter.cs,
182 2008-08-29 Zoltan Varga <vargaz@gmail.com>
184 * RxInterpreter.cs RxCompiler.cs RxOp.cs: Implement/fix this so all the
185 regex tests now run. The Repeat code is taken from the old interpreter.
187 2008-08-28 Zoltan Varga <vargaz@gmail.com>
189 * RxInterpreter.cs RxCompiler.cs RxOp.cs: Add support for
190 Category.AnySingleline.
192 2008-08-27 Zoltan Varga <vargaz@gmail.com>
194 * RxCompiler.cs: Use Array.Copy since Buffer.BlockCopy operates on bytes.
196 2008-07-31 Jb Evain <jbevain@novell.com>
198 * BaseMachine.cs: clean up for NET_2_1.
200 2008-06-05 Roei Erez <roeie@mainsoft.com>
202 * JvmReMachine.jvm.cs: Fix a bug in match that contains
203 empty group at the end.
205 2008-04-13 Jb Evain <jbevain@novell.com>
207 * Regex.cs: update undocumented fields for the 2.1 profile.
208 Merged from the Moonlight 2 branch.
210 2008-02-26 Zoltan Varga <vargaz@gmail.com>
212 * CILCompiler.cs: Implement StringIgnoreCase.
214 * CILCompiler.cs: Implement grouping support.
216 * CILCompiler.cs: Implement character groups.
218 2008-02-25 Zoltan Varga <vargaz@gmail.com>
220 * CILCompiler.cs: Implement lots of missing opcodes.
222 2008-02-18 Zoltan Varga <vargaz@gmail.com>
224 * CILCompiler.cs (EmitEvalMethodBody): Check for the not-yet supported
227 Thu Feb 14 19:03:00 CET 2008 Paolo Molaro <lupus@ximian.com>
229 * RxCompiler.cs, RxInterpreter.cs, RxOp.cs, CILCompiler.cs : support for word
230 boundary position opcodes, ignorecase backreference and more capture
233 Thu Feb 14 17:11:10 CET 2008 Paolo Molaro <lupus@ximian.com>
235 * RxCompiler.cs, RxInterpreter.cs, RxOp.cs: replace EcmaDigit with
236 Range, fixed matching of "" =~ /$/, implementedt TestCharGroup.
237 Fixes and other misc opcodes implemented.
239 2008-02-13 Zoltan Varga <vargaz@gmail.com>
241 * CILCompiler.cs: Restructure some code to avoid a branch inside a loop.
243 * CILCompiler.cs: Fix the unsafe string matching code.
245 * CILCompiler.cs: Improved version which emits only one method in most cases.
247 * CILCompiler.cs: Fix some comments.
249 * CILCompiler.cs: New file, extracted from RxCompiler.cs.
251 * RxInterpreter.cs RxCompiler.cs: First version of regex IL compiler.
253 Wed Feb 13 13:18:12 CET 2008 Paolo Molaro <lupus@ximian.com>
255 * RxCompiler.cs, RxInterpreter.cs, RxOp.cs: unicode categories and
256 some grouping/capture support.
258 Tue Feb 12 19:16:49 CET 2008 Paolo Molaro <lupus@ximian.com>
260 * RxCompiler.cs, RxInterpreter.cs, RxOp.cs: experimental new
263 2008-02-10 Zoltan Varga <vargaz@gmail.com>
265 * replace.cs (NeedsGroupsOrCaptures): New property. Determines whenever the
266 replacement process needs access to the groups or captures properties of the
269 * Group.cs: Add an internal ctor which avoids allocations.
273 * BaseMachine.cs interpreter.cs: Add an optimization to avoid fully creating
274 Match objects during Replace () if the replacement string is simple.
276 * BaseMachine.cs Regex.cs: Make LTRReplace and RTLReplace instance methods to
277 avoid creating two machines for each Regex.Replace () call.
279 * interpreter.cs (Eval): Remove a needless string allocation.
281 2007-12-04 Arina Itkes <arinai@mainsoft.com>
283 * parser.cs: Max value of m for a construct {n,m} is 2147483647.
285 2007-11-15 Miguel de Icaza <miguel@novell.com>
287 * Revert the patch from Juraj Skripsky as it made the class
288 non-thread safe (see #341986).
290 2007-11-08 Raja R Harinath <harinath@gmail.com>
293 * BaseMachine.cs (LTRReplace): Don't use non-advancement of 'ptr'
294 to deduce absence of matches -- a match can have length 0.
295 (RTLReplace): Likewise.
297 2007-11-07 Raja R Harinath <harinath@gmail.com>
299 Support RegexOptions.RightToLeft in Replace().
300 * BaseMachine.cs (Replace): Use either LTRReplace or RTLReplace
302 (LTRReplace): Make internal and rename the MatchAppendEvaluator
303 version of Replace to this.
305 * Regex.cs (Replace): Use LTRReplace and RTLReplace from BaseMachine.
306 * replace.cs (ReplacementEvaluator.Evaluate): Optimize simple case.
307 Based on patch by Stephane Delcroix.
309 * replace.cs (Compile): Don't unescape string.
311 2007-11-01 Gert Driesen <drieseng@users.sourceforge.net>
313 * Match.cs: Do not throw NotSupportedException on zero-length
314 replacement argument.
316 2007-10-29 Arina Itkes <arinai@mainsoft.com>
318 * Regex.cs: Moving creation of Regex machine to ctor.
319 It increases an initialization time of Regex but reduce a
320 process time while APIs calling. Also it solves the problem
321 of missed multi thread synchronization.
323 2007-10-29 Arina Itkes <arinai@mainsoft.com>
325 * Match.cs: Fix for Result method of Match. Throwing an exception
326 if Result method was called on a failed Match.
328 2007-10-24 Juraj Skripsky <js@hotfeet.ch>
330 * Regex.cs: Store and re-use IMachine, no need to re-instantiate
331 it every time we're matching.
333 2007-10-24 Arina Itkes <arinai@mainsoft.com>
335 * Regex.cs Match.cs arch.cs compiler.cs interpreter.cs
336 Refactoring of Interpreter with extracting of base abstract class
337 that executes some methods that were moved from Regex and Match classes.
338 Added a field that maps group numbers to group names in Regex for
339 improvement of performance of GroupNameFromNumber method.
341 2007-10-21 Gert Driesen <drieseng@users.sourceforge.net>
343 * RegexTest.cs: Removed. Test was already moved to the appropriate
346 2007-06-21 Juraj Skripsky <js@hotfeet.ch>
348 * quicksearch.ch: Optimization. Add byte array as skip table for
349 chars <= 255, falling back to the hashtable for chars > 255 and
350 skip distances > 255.
352 2007-04-18 Raja R Harinath <rharinath@novell.com>
355 * parser.cs (ResolveReferences): Don't throw an expression if a
356 capture assertion reference cannot be resolved.
357 (ParseGroupingConstruct): Provide fallback expression to a capture
359 * syntax.cs (CaptureAssertion): If the bareword doesn't refer to
360 the name of a capture group, fallback to treating it as a literal
363 2007-04-04 Raja R Harinath <rharinath@novell.com>
365 * interpreter.cs (Eval) <OpCode.Reference>: Distribute for loop
367 for () if (a) s1; else s2; => if (a) for () s1; else for () s2;
369 2007-04-03 Raja R Harinath <rharinath@novell.com>
371 * Regex.cs (~Regex): Don't define in NET_2_0 profile.
373 2007-01-02 Raja R Harinath <rharinath@novell.com>
376 * parser.cs (Parser.GetMapping): Use the actual group numbers to
379 2006-09-28 Andrew Skiba <andrews@mainsoft.com>
381 * Regex.cs: TARGET_JVM
383 2006-05-30 Gert Driesen <drieseng@users.sourceforge.net>
385 * CaptureCollection.cs: Removed virtual keyword to fix API mismatches.
386 * MatchCollection.cs: Removed virtual keyword to fix API mismatches.
387 * GroupCollection.cs: Removed virtual keyword to fix API mismatches.
389 2006-05-08 Raja R Harinath <rharinath@novell.com>
392 Remove 65535-limit on number of repetitions matched by a pattern.
393 We still have a 65535 limit on the length of a pattern and the
394 number of groups in a pattern.
395 * compiler.cs (PatternCompiler.EmitCount): New. Emits an int as
396 two ushorts into the program stream.
397 (EmitInfo, EmitRepeat, EmitFastRepeat): Use it to emit integers
399 * interpreter.cs (Intepreter.ReadProgramCount): Read an int
400 emitted into the program stream.
401 (Interpreter): Use it. Update counts.
402 (Interpreter.Eval) [OpCode.Repeat, OpCode.FastRepeat]: Likewise.
403 * parser.cs (ParseGroup): Pass 0x7ffffff as the max value for '*'
404 and '+' repetition patterns.
405 * arch.cs (Info, Repeat, FastRepeat): Update description.
407 2006-04-18 Raja R Harinath <rharinath@novell.com>
409 Treat fixed repetitions of simple regexes as simple too.
410 * syntax.cs (Expression.IsComplex): Make abstract.
411 (Group.IsComplex, Alternation.IsComplex): Move ...
412 (CompositeExpression.IsComplex): ... here.
413 (Group.GetAnchorInfo): Reduce allocations. Avoid creating another
414 ArrayList, and use a StringBuilder to build up the string.
415 (Repetition.GetAnchorInfo): Use a StringBuilder to build up the string.
416 (ExpressionAssertion.IsComplex): Override.
418 2006-04-17 Florian Gross <flgr@ccan.de>
419 Raja R Harinath <rharinath@novell.com>
421 * syntax.cs (CharacterClass.Compile): Emit categories after the
422 character intervals so that the evaluator can pick up the
425 2006-04-07 Raja R Harinath <rharinath@novell.com>
428 * interpreter.cs (Interpreter.Eval) [Anchor, Position.StartOfString]:
429 Don't reset 'ptr' to 0 during forward scan.
432 * interpreter.cs (Interpreter.FastEval) [FastRepeat]: If the first
433 tail operation has a 'negate' flag, avoid the "match next char"
437 * arch.cs (OpCode.NotCategory): New. Stands for matching a
438 character _not_ from the given category.
439 * debug.cs (DisassembleBlock): Handle it.
440 * compiler.cs (ICompiler.EmitNotCategory): New.
441 (Compiler.EmitNotCategory): New. Emit OpCode.NotCategory.
442 * syntax.cs (CharacterClass.Compile): Don't conflate negation of
443 the character class and negation of the category. Use
445 * interpreter.cs (Interpreter.Eval): Pass OpCode.NotCategory to
447 (Interpreter.EvalChar): Handle it.
449 2006-04-06 Raja R Harinath <rharinath@novell.com>
452 * interpreter.cs (Eval) [Until, FastUntil]: Set 'deep' to null
453 when evaluating the tail. Ensure that backtracks don't confuse
454 the recursion vs. iteration detector.
456 2006-04-03 Raja R Harinath <rharinath@novell.com>
458 * interpreter.cs (Eval) [Until, lazy]: Avoid extra evaluation on a
461 2006-03-30 Raja R Harinath <harinath@gmail.com>
464 * parser.cs (Parser.ParseCharacterClass): Don't automatically
465 assume there's a range when we see '-'. Ensure that we have seen
466 at least one other character, and that we aren't already parsing a
467 range. Handle some more errors.
469 2005-12-19 Kornél Pál <kornelpal@hotmail.com>
471 * Regex.cs: Added support for regular expressions compiled to
472 assemblies by compiling the pattern. This solution ignores existing
473 CIL code but provides full support for regular expression classes
476 2005-11-21 Sebastien Pouliot <sebastien@ximian.com>
478 * CaptureCollection.cs: Fixed length check.
479 * Group.cs: Added missing validation for Synchronized method.
480 * Match.cs: Added missing validation for Synchronized and Result
482 * MatchEvaluator.cs: Added [Serializable] for 2.0 profile.
483 * RegexCompilationInfo.cs: Added missing property validation.
484 * Regex.cs: Implemented UseOptionC and UseOptionR protected methods
485 (now documented). Fixed API for 2.0 profile.
486 * RegexRunner.cs: Stubbed CharInClass for 2.0 profile.
488 2005-11-17 Sebastien Pouliot <sebastien@ximian.com>
490 * Match.cs: Removed the ": base ()" on the private ctor as it is
491 unrequired and cause an extra public ctor to added (bug #76736).
492 * MatchCollection.cs: Add missing virtual to indexer property.
494 2005-09-23 Raja R Harinath <rharinath@novell.com>
496 * interpreter.cs (Interpreter.Eval) [OpCode.Until]: Invert the
497 sense of a test to reflect the code re-organization.
499 2005-09-22 Raja R Harinath <rharinath@novell.com>
502 * interpreter.cs (Interpreter.Eval) [OpCode.Until]: Avoid some
503 cases of recursion when dealing with eager quantifiers too. We
504 now avoid recursion when handling the innermost quantifier.
505 (Interpreter.IntStack, Interpreter.stack): New. Stack to help
506 implement backtracking in eager quantifiers.
508 2005-09-21 Raja R Harinath <rharinath@novell.com>
510 * interpreter.cs (Interpreter.Eval) [OpCode.Until]: Avoid some
511 cases of recursion when dealing with the minimum count and lazy
514 2005-08-23 Raja R Harinath <rharinath@novell.com>
516 * regex.cs: Remove. Split into ...
517 * MatchEvaluator.cs, Regex.cs, RegexCompilationInfo.cs,
518 RegexOptions.cs: ... these. Now every publicly exposed type in
519 this namespace has its own file.
521 2005-07-21 Florian Gross <flgr@ccan.de>
523 * Fixed a bug in category.cs that caused ECMAScript \d to fail.
525 2005-07-13 Raja R Harinath <rharinath@novell.com>
527 Make even more lazier.
528 * MatchCollection.cs (TryToGet): Don't generate match i+1 when
529 we're looking for match i. Change post-conditions.
530 (FullList): New helper property. Ensures the list is fully populated.
531 (Count, CopyTo): Use it.
532 (Enumerator.Current): Update to new post-conditions of TryToGet.
533 (Enumerator.MoveNext): Likewise. Don't modify index if we're
536 2005-07-08 Raja R Harinath <rharinath@novell.com>
538 * MatchCollection.cs: Convert to incremental mode.
539 * regex.cs (Regex.Matches): Update. Pass responsibility of
540 generating all matches to MatchCollection.
542 2005-06-14 Raja R Harinath <harinath@gmail.com>
544 * parser.cs (Parser.ConsumeWhitespace): Add bounds check.
547 * Match.cs (Match) [zero-argument variant]: Make private.
548 * GroupCollection (Item) [string variant]: Don't look for the
549 group number in an empty match.
551 2005-06-10 Raja R Harinath <rharinath@novell.com>
553 * interpreter.cs (Interpreter.GenerateMatch): Avoid allocating two
554 intermediate arrays to build the final result.
555 (Interpreter.GetGroupInfo, Interpreter.PopulateGroup): New helper
557 * CaptureCollection.cs (list): Change from ArrayList to list.
558 (SetValue): New internal helper, used by Interpreter.PopulateGroup.
559 (Enumerator): Remove helper class.
560 (IEnumerator.GetEnumerator): Just use list.GetEnumerator.
561 * GroupCollection.cs: Likewise.
562 * Group.cs (Group): Move responsibility of populating 'Captures'
563 to Interpreter.PopulateGroup.
564 * Match.cs (Match): Move responsibility of populating 'Groups' to
565 Interpreter.GenerateMatch.
567 2005-05-25 Raja R Harinath <rharinath@novell.com>
569 * replace.cs (ReplacementEvaluator.Compile): Rewrite to avoid
570 creating several intermediate strings. Simplify internal
571 intermediate representation.
572 (ReplacementEvaluator.EvaluateAppend): New. Version of Evaluate
573 that builds the result directly on a passed-in StringBuilder.
574 (ReplacementEvaluator.Evaluate): Just a wrapper around
576 * regex.cs (MatchAppendEvaluator): New internal delegate.
577 (Regex.Replace): Use MatchAppendEvaluator.
578 (Regex.Adapter): New class used to adapt a MatchEvaluator to a
579 MatchAppendEvaluator.
581 2005-05-24 Raja R Harinath <rharinath@novell.com>
583 * replace.cs (ReplacementEvaluator.CompileTerm): Fix group
586 2005-05-20 Ben Maurer <bmaurer@ximian.com>
588 * regex.cs: Some memory allocation optimizations.
590 2005-05-20 Raja R Harinath <rharinath@novell.com>
593 * replace.cs (ReplacementEvaluator.Compile): Allow CompileTerm to
594 fail and yet have advanced the pointer. Append the scanned-over
595 portion to the "literal" being built.
596 (ReplacementEvaluator.CompileTerm): Don't throw any exceptions.
597 If a term cannot be recognized, just return null.
599 * compiler.cs (InterpreterFactory.GroupCount): Fix. The 0'th
600 index corresponds to Opcode.Info.
602 * parser.cs (Parser.Unescape): If the string doesn't contain any
603 '\' character, don't allocate a new string.
605 * replace.cs (ReplacementEvalutator.Term.AppendResult): Rename
606 from GetResult. Append to a passed-in StringBuilder rather than
608 (ReplacementEvaluator.Evaluate): Update.
610 * Capture.cs, Group.cs, Match.cs: New files split out of ...
611 * match.cs: ... this. Remove.
613 2005-02-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
615 * parser.cs: stuff inside {} might not be a quantifier. Fixes
618 2005-01-10 Gonzalo Paniagua Javier <gonzalo@ximian.com>
620 * quicksearch.cs: handle IgnoreCase when getting the shift distance.
621 Fixes bug #69065. Patch by mei@work.email.ne.jp.
623 2005-01-08 Miguel de Icaza <miguel@ximian.com>
625 * syntax.cs: Applied patch from mei@work.email.ne.jp to fix bug
628 * parser.cs: Turns out that \digit sequences are octal sequences
629 (no leading zero is needed); And the three octal digit rule
630 applies to the leading zero as well.
632 This fixes the Unescape method.
634 2004-11-29 Gonzalo Paniagua Javier <gonzalo@ximian.com>
636 * regex.cs: use NextMatch to move on to the next match. Fixes bug
639 2004-11-09 Atsushi Enomoto <atsushi@ximian.com>
643 2004-11-08 Ben Maurer <bmaurer@ximian.com>
645 * replace.cs, parser.cs: Use stringbuilder for allocation sanity.
647 2004-10-21 Joerg Rosenkranz <joergr@voelcker.com>
649 * regex.cs: Fixed a bug introduced with the last patch which
650 prevented any replacements when a postive count is given.
651 This also happens in all overloads without count parameter.
653 2004-10-18 Gonzalo Paniagua Javier <gonzalo@ximian.com>
655 * regex.cs: in Replace, when count is negative, replacement continues
656 to the end of the string.
658 Fixes bug #68398. Patch by Jon Larimer.
660 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
662 * RegexRunner.cs: fixed case mismatch of methods
664 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
666 * RegexRunner.cs: marked TODO, added missing protected internal
667 fields, throw NotImplementedException in all methods
669 2004-06-10 Gert Driesen <drieseng@users.sourceforge.net>
671 * RegexRunnerFactory.cs: removed comment, no longer throw exception
673 * regex.cs: fixed public API signature by renaming protected
674 internal fields and adding destructor, added MonoTODO attribute to
675 fields and method that are not yet implemented, changed not
676 implemented methods to throw NotImplementedException instead of
677 Exception, fixed names of field that are serialized
679 2004-06-06 Jambunathan K <kjambunathan@novell.com>
681 * parser.cs: Fixed issues with Regex.Unescape() identified as part of
682 debugging bug #58256. The original problem reported was about
683 inconsistency between the way we treat replacement patterns and the
684 way microsoft treats the replacement patterns in Regex.Replace(). MS
685 implementation is buggy and doesn't honour escape sequences in the
686 replacement patterns, even though the SDK claims otherwise.
689 2004-06-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
691 * syntax.cs: re-applied my patch from 2004-05-27 plus a fix which is
692 emitting a Category.All if both a category and its negated value are
695 2004-06-01 Gonzalo Paniagua Javier <gonzalo@ximian.com>
697 * syntax.cs: reverting my previous patch. It causes bigger problems.
699 2004-05-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
701 * category.cs: added LastValue field to mark the end of enum Category.
702 * syntax.cs: in CharacterClass, use Category.LastValue to get the size
703 of the array needed. Use a BitArray instead of bool[].
704 In AddCategory(), don't set the opposite category as false. Fixes
705 bug #59150. All tests pass.
707 2004-05-25 Jackson Harper <jackson@ximian.com>
709 * parser.cs: Allow creating a regular expression using {,n} as the
710 specified. The min bounds is set to -1, I am not completely sure
711 if that is what it is supposed to be but MS does not set it to 0
712 based on testing. Patch by dave-gnome-bugs@earth.li. Fixes bug #56761.
714 2004-05-12 Dick Porter <dick@ximian.com>
718 * RegexRunnerFactory.cs:
719 * RegexRunner.cs: More public API difference fixes.
721 * GroupCollection.cs:
722 * MatchCollection.cs:
723 * CaptureCollection.cs: Moved GroupCollection, MatchCollection and
724 CaptureCollection so that they no longer inherit from the
725 non-standard RegexCollectionBase class. Fixes the API difference.
727 2004-04-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
734 Patch by Eric Durand Tremblay.
735 1) Capture inner group when named.
736 2) Resolved parse error caused by not capturing inner group
737 3) Resolved incorrect capture group
738 4) Now, not capturing anything when unnamed ( correct behavior)
741 2004-04-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
747 * syntax.cs: converted to unix line endings.
749 2004-03-30 Lluis Sanchez Gual <lluis@ximian.com>
751 * collections.cs: In the indexer, return an empty group if the requested
753 * match.cs: Added default constructor for Group.
755 2004-03-24 Gonzalo Paniagua Javier <gonzalo@ximian.com>
757 * parser.cs: fixed group numbering.
759 2004-03-22 Jackson Harper <jackson@ximian.com>
761 * parser.cs: Use the group number as the name in mapping. Patch by
763 * regex.cs: Fix off by one error. Patch by Gert Driesen.
765 2004-03-17 Francois Beauchemin <beauche@softhome.net>
766 * syntax.cs, interpreter.cs, quicksearch.cs, regex.cs, compiler.cs :
767 Revised support for RigthToLeft.
768 quicksearch has now an reverse option.
769 This fixes bug #54537
771 * regex.cs, compiler.cs :
772 Some code to support CILCompiler.
774 Added some undocumented of MS.
776 2004-03-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
778 * parser.cs: allow a @"\0" escape sequence. Fixes bug #54797.
780 2004-02-01 Miguel de Icaza <miguel@ximian.com>
782 * syntax.cs, interval.cs: Applied patch from Marco Cravairo
783 through Francois Beauchemin who reviewed on the mailing list.
784 This fixes bug #45976
786 2004-01-16 Gonzalo Paniagua Javier <gonzalo@ximian.com>
788 * parser.cs: an opening brace without a
789 quantifier do not cause a parse error. Fixes bug #52924.
791 2004-01-07 Lluis Sanchez Gual <lluis@ximian.com>
793 * regex.cs: In Split(), if the last match is at the end of the string,
794 an empty string must be added to the array of results.
796 2003-12-15 Sanjay Gupta <gsanjay@novell.com>
797 * match.cs: Check for null value before Substring method call.
800 2003-11-21 Juraj Skripsky <js@hotfeet.ch>
802 * quicksearch.cs: Create and use hashtable only for "long" search
805 (Search): Use simple scan for a single-character search strings.
807 (GetChar): Simplify case sensitivity handling.
809 2003-11-27 Gonzalo Paniagua Javier <gonzalo@ximian.com>
811 * interpreter.cs: when evaluating a degenerate match, restore the
812 RepeatContext if fail. Fixes bug #42529.
814 2003-11-22 Jackson Harper <jackson@ximian.com>
816 * regex.cs: Add CultureInvariant flag to RegexOptions.
818 2003-11-20 Juraj Skripsky <js@hotfeet.ch>
820 * quicksearch.cs: Use a hashtable instead of an array for the
821 shift table to improve the memory usage.
823 2003-11-19 Gonzalo Paniagua Javier <gonzalo@ximian.com>
826 (Split): include capture groups in the results, if any. Fixes bug
829 2003-07-09 Gonzalo Paniagua Javier <gonzalo@ximian.com>
831 * regex.cs: patch from Eric Lindvall <eric@5stops.com> that fixes bug
834 2003-03-05 Miguel de Icaza <miguel@ximian.com>
836 * category.cs (CategoryUtils.CategoryFromName): Use StartsWith
837 ("Is") instead of a substring for (0,2) which was throwing an
838 exception causing Category.None to be returned
840 2003-01-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
842 * collections.cs: fixed bug #30091.
844 2002-12-20 Gonzalo Paniagua Javier <gonzalo@ximian.com>
846 * regex.cs: fixed little mistake (closes #35860).
848 2002-11-12 Jackson Harper <jackson@latitudegeo.com>
850 * arch.cs compiler.cs regex.cs: Added mapping attribute to MachineFactories
852 2002-11-06 Gonzalo Paniagua Javier <gonzalo@ximian.com>
854 * parser.cs: detect illegal \ at end of pattern. Fixes 31334.
856 2002-10-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
858 * parser.cs: applied fix from Tim Haynes (thaynes@openlinksw.com) to
859 solve bug #32807. Also modified GetMapping to return the same as MS.
861 2002-08-28 Juli Mallett <jmallett@FreeBSD.org>
863 * arch.cs, compiler.cs: Give the interpreter machine a property
864 for the retrieval of the group count.
866 * regex.cs: Use the new GroupCount property of the factory to
867 initialise the current group count, and restructure code to compile
868 the pattern only the first time it is needed (essentially backing
869 out the previous revision of regex.cs, to use the new code.)
871 2002-08-14 Cesar Octavio Lopez Nataren <cesar@ciencias.unam.mx>
873 * regex.cs: Added the ctr for ISerializable implementation and
874 implemented the GetObjectData function.
876 2002-07-30 Juli Mallett <jmallett@FreeBSD.org>
878 * regex.cs: Fixed bug where the expression would not be
879 re-evaluated for grouping purposes when factory caches were
880 used, resulting in no groups being recognised after one call
881 with a given pattern and no change in options.
883 2002-05-13 Dan Lewis <dihlewis@yahoo.co.uk>
885 * regex.cs: Fixed bug in split.
887 2002-05-08 Dan Lewis <dihlewis@yahoo.co.uk>
889 * interpreter.cs: Moved to an array-based stack representation
892 * match.cs, collections.cs: Decoupled capture representation from
893 interpreter internals.
895 * cache.cs: Changed Key type from struct to class for speed.
897 2002-04-06 Dan Lewis <dihlewis@yahoo.co.uk>
899 * cache.cs: Object methods should be overridden with "override".
901 2002-04-04 Dan Lewis <dihlewis@yahoo.co.uk>
903 * RegexRunner.cs, RegexRunnerFactory.cs: MS support classes. Stubs
904 added for completeness.
906 * regex.cs, match.cs, collections.cs: Serializable attribute.
908 2002-04-04 Dan Lewis <dihlewis@yahoo.co.uk>
910 * regex.cs: Added static Matches and IsMatch methods.
912 2002-04-03 Dan Lewis <dihlewis@yahoo.co.uk>
914 * ChangeLog: Added changelog.
916 * cache.cs: Fixed bug in MRUList.Evict.