Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > Is it safe to shre a reg exp object among threads?

Reply
Thread Tools

Is it safe to shre a reg exp object among threads?

 
 
overly.crazy.steve@gmail.com
Guest
Posts: n/a
 
      06-29-2006
Let's say I construct a regular expression object r by:

r = re.compile("some pattern")

Is it safe to let multiple threads to use r concurrently (use r.search
on different strings, etc.)?

Thanks.

 
Reply With Quote
 
 
 
 
Fredrik Lundh
Guest
Posts: n/a
 
      06-29-2006
http://www.velocityreviews.com/forums/(E-Mail Removed) wrote:

> Let's say I construct a regular expression object r by:
>
> r = re.compile("some pattern")
>
> Is it safe to let multiple threads to use r concurrently (use r.search
> on different strings, etc.)?


yes.

</F>

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
reg exp Ken Chesak Perl 5 09-01-2004 12:27 PM
reg exp Ken Chesak Perl 0 08-26-2004 03:40 PM
Reg Exp Help PerlE Perl 0 01-30-2004 06:15 AM
Newbie-Reg Exp psk Perl 2 01-19-2004 10:30 PM
Reg exp: matching relative path only. Andrew Rowland Perl 0 08-01-2003 11:14 PM



Advertisments