more regexp caching

This commit is contained in:
Alexey Verkhovsky 2005-02-04 19:00:28 +00:00
parent 9ea307b9d2
commit ace569ae05
4 changed files with 10 additions and 6 deletions

View file

@ -7,7 +7,8 @@ require 'chunks/wiki'
# of changes to that page.
# If the included page could not be found, a warning is displayed.
class Include < WikiChunk::WikiLink
def self.pattern() /^\[\[!include(.*)\]\]\s*$/i end
INCLUDE_PATTERN = /^\[\[!include(.*)\]\]\s*$/i
def self.pattern() INCLUDE_PATTERN end
attr_reader :page_name