From a097a36e2a86f9b5209aea546f3c4cf5064aec87 Mon Sep 17 00:00:00 2001 From: Igor Kudrin Date: Fri, 5 Aug 2016 16:48:31 +0000 Subject: [PATCH] Fix gdb pretty printers to work with Python 3. Differential Revision: https://reviews.llvm.org/D23202 llvm-svn: 277833 --- llvm/utils/gdb-scripts/prettyprinters.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/llvm/utils/gdb-scripts/prettyprinters.py b/llvm/utils/gdb-scripts/prettyprinters.py index 0dbc7af..1ebe50b 100644 --- a/llvm/utils/gdb-scripts/prettyprinters.py +++ b/llvm/utils/gdb-scripts/prettyprinters.py @@ -46,6 +46,8 @@ class SmallVectorPrinter: self.cur = self.cur + 1 return '[%d]' % count, cur.dereference() + __next__ = next + def __init__(self, val): self.val = val @@ -86,6 +88,8 @@ class ArrayRefPrinter: self.cur = self.cur + 1 return '[%d]' % count, cur.dereference() + __next__ = next + def __init__(self, val): self.val = val -- 2.7.4