summaryrefslogtreecommitdiff
path: root/django/utils/dateformat.py
diff options
context:
space:
mode:
Diffstat (limited to 'django/utils/dateformat.py')
-rw-r--r--django/utils/dateformat.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/django/utils/dateformat.py b/django/utils/dateformat.py
index d3f586aacf..836b40a70a 100644
--- a/django/utils/dateformat.py
+++ b/django/utils/dateformat.py
@@ -12,17 +12,17 @@ Usage:
"""
import calendar
import datetime
-import re
import time
from django.utils.dates import (
MONTHS, MONTHS_3, MONTHS_ALT, MONTHS_AP, WEEKDAYS, WEEKDAYS_ABBR,
)
+from django.utils.regex_helper import _lazy_re_compile
from django.utils.timezone import get_default_timezone, is_aware, is_naive
from django.utils.translation import gettext as _
-re_formatchars = re.compile(r'(?<!\\)([aAbBcdDeEfFgGhHiIjlLmMnNoOPrsStTUuwWyYzZ])')
-re_escaped = re.compile(r'\\(.)')
+re_formatchars = _lazy_re_compile(r'(?<!\\)([aAbBcdDeEfFgGhHiIjlLmMnNoOPrsStTUuwWyYzZ])')
+re_escaped = _lazy_re_compile(r'\\(.)')
class Formatter: