summaryrefslogtreecommitdiff
path: root/morphlib/morph2.py
diff options
context:
space:
mode:
Diffstat (limited to 'morphlib/morph2.py')
-rw-r--r--morphlib/morph2.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/morphlib/morph2.py b/morphlib/morph2.py
index 6af9e9e5..4fdf7ba4 100644
--- a/morphlib/morph2.py
+++ b/morphlib/morph2.py
@@ -1,4 +1,4 @@
-# Copyright (C) 2012 Codethink Limited
+# Copyright (C) 2012-2013 Codethink Limited
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -17,7 +17,10 @@
import copy
import re
-try:
+# It is intentional that if collections does not have OrderedDict that
+# simplejson is also used in preference to json, as OrderedDict became
+# a member of collections in the same release json got its object_pairs_hook
+try: # pragma: no cover
from collections import OrderedDict
import json
except ImportError: # pragma: no cover