error redefinition of group name
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this error redefinition of typedef site About Us Learn more about Stack Overflow the company Business Learn error redefinition of typedef 'gliststore' more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question
Error Redefinition Of 'classx Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Regex
Error Redefinition Of ‘classProblem Group Name Redefinition? up vote 4 down vote favorite 4 So I have this regex: (^(\s+)?(?P
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about
Error Redefinition Of ‘structStack Overflow the company Business Learn more about hiring developers or posting ads error redefinition of 'struct iovec' with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow error redefinition of default argument is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Python Regex - Is it possible to use the same group (named or http://stackoverflow.com/questions/363171/regex-problem-group-name-redefinition unnamed) in multiple spots? up vote 0 down vote favorite I have a bunch of strings, some of which I need to replace a part of. However, the parts before and after the parts that need to be replaced are not always the same. Also, the part of the string that needs to be replaced is not something I can match with a regex without it matching other parts that http://stackoverflow.com/questions/21999677/python-regex-is-it-possible-to-use-the-same-group-named-or-unnamed-in-multip I don't want to replace. For example: "prefixA_REPLACEME_postfixA", "prefixB_SOMETHING_postfixB", "prefixA_LLAMAS_postfixC", "prefixB_DONTREPLACE_postfixA", Turned into: "prefixA_NEWSTR_postfixA", "prefixB_NEWSTR_postfixB", "prefixA_NEWSTR_postfixC", "prefixB_DONTREPLACE_postfixA", I would love to do this with a single regex, like this: re.sub('(prefixA_).*(_postfixA)|(prefixB_).*(_postfixB)|(prefixA_).*(_postfixC)', '\\1NEWSTR\\2', stringToFix) Unfortunately this doesn't work, because group 1 and group 2 are (prefixA_) and (postfixA), whether or not that is the part of the regex that ends up being used. I also can't use this re.sub('(?P
User List Committer List Help Tracker Documentation Tracker Development Report Tracker Problem Issue4430 classification Title: time.strptime does not allow same format directive twice Type: behavior Stage: needs patch Components: Versions: Python 2.5 process Status: closed Resolution: wont fix http://bugs.python.org/issue4430 Dependencies: Superseder: Assigned To: Nosy List: brett.cannon, mrabarnett, sil Priority: low Keywords: Created on 2008-11-25 16:36 by sil, last changed 2010-08-04 23:30 by terry.reedy. This issue is now closed. Messages (3) msg76417 - (view) Author: https://recalll.co/app/?q=python%20-%20Regex%20Problem%20Group%20Name%20Redefinition%3F%20-%20Stack%20Overflow (sil) Date: 2008-11-25 16:36 $ python -c "import time; print time.strptime('25/11/2008 25/11/2008','%d/%m/%y %d/%m/%y')" Traceback (most recent call last): File "
as far as possible. I made the following assumptions: You want to (correct me if I'm wrong): "01f.foo" "." followed by the end of the string You could also have meant: ^\s*(?P