Functions | Variables
gmock_doctor Namespace Reference

Functions

def _FindAllMatches (regex, s)
 
def _GenericDiagnoser (short_name, long_name, diagnoses, msg)
 
def _IncompleteByReferenceArgumentDiagnoser (msg)
 
def _MockObjectPointerDiagnoser (msg)
 
def _NeedToReturnNothingDiagnoser (msg)
 
def _NeedToReturnReferenceDiagnoser (msg)
 
def _NeedToReturnSomethingDiagnoser (msg)
 
def _NeedToUseReturnNullDiagnoser (msg)
 
def _NeedToUseSymbolDiagnoser (msg)
 
def _OverloadedFunctionActionDiagnoser (msg)
 
def _OverloadedFunctionMatcherDiagnoser (msg)
 
def _OverloadedMethodActionDiagnoser (msg)
 
def _TypeInTemplatedBaseDiagnoser (msg)
 
def _WrongMockMethodMacroDiagnoser (msg)
 
def _WrongParenPositionDiagnoser (msg)
 
def Diagnose (msg)
 
def main ()
 

Variables

string __author__ = 'wan@google.com (Zhanyong Wan)'
 
string _CLANG_FILE_LINE_RE = r'(?P<file>.*):(?P<line>\d+):(?P<column>\d+):\s+'
 
tuple _CLANG_NON_GMOCK_FILE_LINE_RE
 
list _COMMON_GMOCK_SYMBOLS
 
list _DIAGNOSERS
 
string _EMAIL = 'googlemock@googlegroups.com'
 
string _GCC_FILE_LINE_RE = r'(?P<file>.*):(?P<line>\d+):(\d+:)?\s+'
 
string _VERSION = '1.0.3'
 

Function Documentation

◆ _FindAllMatches()

def gmock_doctor._FindAllMatches (   regex,
  s 
)
private
Generates all matches of regex in string s.

Definition at line 137 of file gmock_doctor.py.

◆ _GenericDiagnoser()

def gmock_doctor._GenericDiagnoser (   short_name,
  long_name,
  diagnoses,
  msg 
)
private
Diagnoses the given disease by pattern matching.

Can provide different diagnoses for different patterns.

Args:
  short_name: Short name of the disease.
  long_name:  Long name of the disease.
  diagnoses:  A list of pairs (regex, pattern for formatting the diagnosis
              for matching regex).
  msg:        Compiler's error messages.
Yields:
  Tuples of the form
    (short name of disease, long name of disease, diagnosis).

Definition at line 144 of file gmock_doctor.py.

◆ _IncompleteByReferenceArgumentDiagnoser()

def gmock_doctor._IncompleteByReferenceArgumentDiagnoser (   msg)
private
Diagnoses the IBRA disease, given the error messages by the compiler.

Definition at line 255 of file gmock_doctor.py.

◆ _MockObjectPointerDiagnoser()

def gmock_doctor._MockObjectPointerDiagnoser (   msg)
private
Diagnoses the MOP disease, given the error messages by the compiler.

Definition at line 357 of file gmock_doctor.py.

◆ _NeedToReturnNothingDiagnoser()

def gmock_doctor._NeedToReturnNothingDiagnoser (   msg)
private
Diagnoses the NRN disease, given the error messages by the compiler.

Definition at line 218 of file gmock_doctor.py.

◆ _NeedToReturnReferenceDiagnoser()

def gmock_doctor._NeedToReturnReferenceDiagnoser (   msg)
private
Diagnoses the NRR disease, given the error messages by the compiler.

Definition at line 166 of file gmock_doctor.py.

◆ _NeedToReturnSomethingDiagnoser()

def gmock_doctor._NeedToReturnSomethingDiagnoser (   msg)
private
Diagnoses the NRS disease, given the error messages by the compiler.

Definition at line 191 of file gmock_doctor.py.

◆ _NeedToUseReturnNullDiagnoser()

def gmock_doctor._NeedToUseReturnNullDiagnoser (   msg)
private
Diagnoses the NRNULL disease, given the error messages by the compiler.

Definition at line 416 of file gmock_doctor.py.

◆ _NeedToUseSymbolDiagnoser()

def gmock_doctor._NeedToUseSymbolDiagnoser (   msg)
private
Diagnoses the NUS disease, given the error messages by the compiler.

Definition at line 396 of file gmock_doctor.py.

◆ _OverloadedFunctionActionDiagnoser()

def gmock_doctor._OverloadedFunctionActionDiagnoser (   msg)
private
Diagnoses the OFA disease, given the error messages by the compiler.

Definition at line 303 of file gmock_doctor.py.

◆ _OverloadedFunctionMatcherDiagnoser()

def gmock_doctor._OverloadedFunctionMatcherDiagnoser (   msg)
private
Diagnoses the OFM disease, given the error messages by the compiler.

Definition at line 282 of file gmock_doctor.py.

◆ _OverloadedMethodActionDiagnoser()

def gmock_doctor._OverloadedMethodActionDiagnoser (   msg)
private
Diagnoses the OMA disease, given the error messages by the compiler.

Definition at line 328 of file gmock_doctor.py.

◆ _TypeInTemplatedBaseDiagnoser()

def gmock_doctor._TypeInTemplatedBaseDiagnoser (   msg)
private
Diagnoses the TTB disease, given the error messages by the compiler.

Definition at line 442 of file gmock_doctor.py.

◆ _WrongMockMethodMacroDiagnoser()

def gmock_doctor._WrongMockMethodMacroDiagnoser (   msg)
private
Diagnoses the WMM disease, given the error messages by the compiler.

Definition at line 511 of file gmock_doctor.py.

◆ _WrongParenPositionDiagnoser()

def gmock_doctor._WrongParenPositionDiagnoser (   msg)
private
Diagnoses the WPP disease, given the error messages by the compiler.

Definition at line 539 of file gmock_doctor.py.

◆ Diagnose()

def gmock_doctor.Diagnose (   msg)
Generates all possible diagnoses given the compiler error message.

Definition at line 577 of file gmock_doctor.py.

◆ main()

def gmock_doctor.main ( )

Definition at line 594 of file gmock_doctor.py.

Variable Documentation

◆ __author__

string gmock_doctor.__author__ = 'wan@google.com (Zhanyong Wan)'
private

Definition at line 34 of file gmock_doctor.py.

◆ _CLANG_FILE_LINE_RE

string gmock_doctor._CLANG_FILE_LINE_RE = r'(?P<file>.*):(?P<line>\d+):(?P<column>\d+):\s+'
private

Definition at line 132 of file gmock_doctor.py.

◆ _CLANG_NON_GMOCK_FILE_LINE_RE

tuple gmock_doctor._CLANG_NON_GMOCK_FILE_LINE_RE
private
Initial value:
1 = (
2  r'(?P<file>.*[/\\^](?!gmock-)[^/\\]+):(?P<line>\d+):(?P<column>\d+):\s+')

Definition at line 133 of file gmock_doctor.py.

◆ _COMMON_GMOCK_SYMBOLS

list gmock_doctor._COMMON_GMOCK_SYMBOLS
private

Definition at line 43 of file gmock_doctor.py.

◆ _DIAGNOSERS

list gmock_doctor._DIAGNOSERS
private
Initial value:
1 = [
2  _IncompleteByReferenceArgumentDiagnoser,
3  _MockObjectPointerDiagnoser,
4  _NeedToReturnNothingDiagnoser,
5  _NeedToReturnReferenceDiagnoser,
6  _NeedToReturnSomethingDiagnoser,
7  _NeedToUseReturnNullDiagnoser,
8  _NeedToUseSymbolDiagnoser,
9  _OverloadedFunctionActionDiagnoser,
10  _OverloadedFunctionMatcherDiagnoser,
11  _OverloadedMethodActionDiagnoser,
12  _TypeInTemplatedBaseDiagnoser,
13  _WrongMockMethodMacroDiagnoser,
14  _WrongParenPositionDiagnoser,
15  ]

Definition at line 560 of file gmock_doctor.py.

◆ _EMAIL

string gmock_doctor._EMAIL = 'googlemock@googlegroups.com'
private

Definition at line 41 of file gmock_doctor.py.

◆ _GCC_FILE_LINE_RE

string gmock_doctor._GCC_FILE_LINE_RE = r'(?P<file>.*):(?P<line>\d+):(\d+:)?\s+'
private

Definition at line 131 of file gmock_doctor.py.

◆ _VERSION

string gmock_doctor._VERSION = '1.0.3'
private

Definition at line 39 of file gmock_doctor.py.



libaditof
Author(s):
autogenerated on Wed May 21 2025 02:07:08