Googletest export
Use an OrderedDict to store templated_types in the AST so that gmock knows how to properly construct the templated Mock class. This is necessary for functions that make use of the templated typename as an argument or return type. PiperOrigin-RevId: 349405731
This commit is contained in:
@@ -36,6 +36,7 @@ except ImportError:
|
||||
# Python 2.x
|
||||
import __builtin__ as builtins
|
||||
|
||||
import collections
|
||||
import sys
|
||||
import traceback
|
||||
|
||||
@@ -1433,7 +1434,7 @@ class AstBuilder(object):
|
||||
pass # Not needed yet.
|
||||
|
||||
def _GetTemplatedTypes(self):
|
||||
result = {}
|
||||
result = collections.OrderedDict()
|
||||
tokens = list(self._GetMatchingChar('<', '>'))
|
||||
len_tokens = len(tokens) - 1 # Ignore trailing '>'.
|
||||
i = 0
|
||||
|
||||
Reference in New Issue
Block a user