[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Emacs-diffs] master 938d252 4/4: Make regex matching reentrant; upd

From: Stefan Monnier
Subject: Re: [Emacs-diffs] master 938d252 4/4: Make regex matching reentrant; update syntax during match
Date: Sun, 17 Jun 2018 15:34:45 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

> Oh, yeah. One more thing. The busy flag isn't *just* to prevent the regex
> bytecode engine confusing itself with self-modifying bytecode. It also
> serves to protect the cache slot holding the regex pattern from reuse,
> which would be disastrous whether or not the bytecode of a particular
> pattern happens to be mutable.

It doesn't have to be disastrous *if* we complexify the code such that
removing a pattern from the cache doesn't inevitably free that pattern ;-)
[ But, yes, we'd still need to mark the pattern as "busy" in order to
  know when it can be freed.  ]


reply via email to

[Prev in Thread] Current Thread [Next in Thread]