Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
gmock_doctor Namespace Reference

Functions

def _FindAllMatches
 
def _GenericDiagnoser
 
def _NeedToReturnReferenceDiagnoser
 
def _NeedToReturnSomethingDiagnoser
 
def _NeedToReturnNothingDiagnoser
 
def _IncompleteByReferenceArgumentDiagnoser
 
def _OverloadedFunctionMatcherDiagnoser
 
def _OverloadedFunctionActionDiagnoser
 
def _OverloadedMethodActionDiagnoser
 
def _MockObjectPointerDiagnoser
 
def _NeedToUseSymbolDiagnoser
 
def _NeedToUseReturnNullDiagnoser
 
def _TypeInTemplatedBaseDiagnoser
 
def _WrongMockMethodMacroDiagnoser
 
def _WrongParenPositionDiagnoser
 
def Diagnose
 
def main
 

Variables

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

Function Documentation

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

Definition at line 137 of file gmock_doctor.py.

View newest version in sPHENIX GitHub at line 137 of file gmock_doctor.py

Referenced by _GenericDiagnoser(), _NeedToUseSymbolDiagnoser(), and _TypeInTemplatedBaseDiagnoser().

+ Here is the caller graph for this function:

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.

View newest version in sPHENIX GitHub at line 144 of file gmock_doctor.py

References _FindAllMatches().

Referenced by _IncompleteByReferenceArgumentDiagnoser(), _MockObjectPointerDiagnoser(), _NeedToReturnNothingDiagnoser(), _NeedToReturnReferenceDiagnoser(), _NeedToReturnSomethingDiagnoser(), _NeedToUseReturnNullDiagnoser(), _OverloadedFunctionActionDiagnoser(), _OverloadedFunctionMatcherDiagnoser(), _OverloadedMethodActionDiagnoser(), _TypeInTemplatedBaseDiagnoser(), _WrongMockMethodMacroDiagnoser(), and _WrongParenPositionDiagnoser().

+ Here is the call graph for this function:

+ Here is the caller graph for this function:

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.

View newest version in sPHENIX GitHub at line 255 of file gmock_doctor.py

References _GenericDiagnoser().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 357 of file gmock_doctor.py

References _GenericDiagnoser().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 218 of file gmock_doctor.py

References _GenericDiagnoser().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 166 of file gmock_doctor.py

References _GenericDiagnoser().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 191 of file gmock_doctor.py

References _GenericDiagnoser().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 416 of file gmock_doctor.py

References _GenericDiagnoser().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 396 of file gmock_doctor.py

References _FindAllMatches().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 303 of file gmock_doctor.py

References _GenericDiagnoser().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 282 of file gmock_doctor.py

References _GenericDiagnoser().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 328 of file gmock_doctor.py

References _GenericDiagnoser().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 442 of file gmock_doctor.py

References _FindAllMatches(), and _GenericDiagnoser().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 511 of file gmock_doctor.py

References _GenericDiagnoser().

+ Here is the call graph for this function:

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.

View newest version in sPHENIX GitHub at line 539 of file gmock_doctor.py

References _GenericDiagnoser().

+ Here is the call graph for this function:

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

Definition at line 577 of file gmock_doctor.py.

View newest version in sPHENIX GitHub at line 577 of file gmock_doctor.py

Referenced by main().

+ Here is the caller graph for this function:

def gmock_doctor.main ( void  )

Definition at line 594 of file gmock_doctor.py.

View newest version in sPHENIX GitHub at line 594 of file gmock_doctor.py

References Diagnose().

+ Here is the call graph for this function:

Variable Documentation

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

Definition at line 34 of file gmock_doctor.py.

View newest version in sPHENIX GitHub at line 34 of file gmock_doctor.py

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

Definition at line 132 of file gmock_doctor.py.

View newest version in sPHENIX GitHub at line 132 of file gmock_doctor.py

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

Definition at line 133 of file gmock_doctor.py.

View newest version in sPHENIX GitHub at line 133 of file gmock_doctor.py

list gmock_doctor._COMMON_GMOCK_SYMBOLS

Definition at line 43 of file gmock_doctor.py.

View newest version in sPHENIX GitHub at line 43 of file gmock_doctor.py

list gmock_doctor._DIAGNOSERS
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.

View newest version in sPHENIX GitHub at line 560 of file gmock_doctor.py

string gmock_doctor._EMAIL 'googlemock@googlegroups.com'

Definition at line 41 of file gmock_doctor.py.

View newest version in sPHENIX GitHub at line 41 of file gmock_doctor.py

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

Definition at line 131 of file gmock_doctor.py.

View newest version in sPHENIX GitHub at line 131 of file gmock_doctor.py

string gmock_doctor._VERSION '1.0.3'

Definition at line 39 of file gmock_doctor.py.

View newest version in sPHENIX GitHub at line 39 of file gmock_doctor.py