summaryrefslogtreecommitdiff
path: root/parser.py
diff options
context:
space:
mode:
authorAnthon van der Neut <anthon@mnt.org>2018-08-20 23:58:10 +0200
committerAnthon van der Neut <anthon@mnt.org>2018-08-20 23:58:10 +0200
commitf39bf3cbbc7815cd041ce9c04723209f2aff729e (patch)
treeac50146f5ba84a911e3feae0e0966bb2018d6a9f /parser.py
parent995ff1de4463e9a3d3ab8825049e139320ab4c38 (diff)
downloadruamel.yaml-f39bf3cbbc7815cd041ce9c04723209f2aff729e.tar.gz
some minor speed ups through removal of indirection overhead, re #159
Diffstat (limited to 'parser.py')
-rw-r--r--parser.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/parser.py b/parser.py
index 5443445..9aedcac 100644
--- a/parser.py
+++ b/parser.py
@@ -123,14 +123,14 @@ class Parser(object):
def scanner(self):
# type: () -> Any
if hasattr(self.loader, 'typ'):
- self.loader.scanner
+ return self.loader.scanner
return self.loader._scanner
@property
def resolver(self):
# type: () -> Any
if hasattr(self.loader, 'typ'):
- self.loader.resolver
+ return self.loader.resolver
return self.loader._resolver
def check_event(self, *choices):