Re: AW: AW: Invoking a modifing method for backreferences in Perl5Util.substitute
"Daniel F. Savarese" <[email protected]> Fri, 11 Mar 2005 13:34:13 -0500
| Newsgroups | gmane.comp.jakarta.oro.user |
|---|---|
| Message-ID | <[email protected]> |
In message <[email protected]>, "Sann, St ephan" writes: >The pattern-engine seems to keep a copy of the backreference or whatever. Trie >d to >debug this thing but ended in cryptical code without comments - gave up :-( > > >Any more suggestions? You need to recalculate the begin/end offset info as well (the toUppercase test works because the offset information was the same). That's why I said if you can implement it in a generic way, it's something I think we should definitely add to the API. It'll make life easier for anyone who wants to do this in the future. I know it is considerably more painful to do what you want in Java than in a scripting language. If you see a way of improving the API to make it easire to apply arbitrary modifications to match results before substitution, don't hesitate to make a suggestion. daniel