[issue37998] re.sub(r'\\', r'\\\\', s) reporting MemoryError

2019-09-01 Thread Guruprasad Venkataramaiah


New submission from Guruprasad Venkataramaiah 
:

On Python 3.5:
s = re.sub(r'\\', r'', s)
  File "/pyuniti/venvs/guruv/lib/python3.5/re.py", line 182, in sub
return _compile(pattern, flags).sub(repl, string, count)
MemoryError

On Python 3.7
s = re.sub(r'\\', r'', s)  
  File "C:\Python\Python37-32\lib\re.py", line 192, in sub
return _compile(pattern, flags).sub(repl, string, count)
MemoryError

--
components: Regular Expressions
messages: 350943
nosy: Guruprasad Venkataramaiah, ezio.melotti, mrabarnett
priority: normal
severity: normal
status: open
title: re.sub(r'\\', r'', s) reporting MemoryError
type: resource usage
versions: Python 3.5, Python 3.7

___
Python tracker 
<https://bugs.python.org/issue37998>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue37998] re.sub(r'\\', r'\\\\', s) reporting MemoryError

2019-09-01 Thread Guruprasad Venkataramaiah


Guruprasad Venkataramaiah  added the 
comment:

With more debug, observed the input string ('s') is getting assigned to a big 
string of '' resulting in Memory error

--
resolution:  -> not a bug

___
Python tracker 
<https://bugs.python.org/issue37998>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue37998] re.sub(r'\\', r'\\\\', s) reporting MemoryError

2019-09-01 Thread Guruprasad Venkataramaiah


Guruprasad Venkataramaiah  added the 
comment:

With more debug, observed the input string ('s') is getting assigned to a big 
string of '' resulting in Memory error

--
stage:  -> resolved
status: open -> closed

___
Python tracker 
<https://bugs.python.org/issue37998>
___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com