EDoc::Dictionary Class Reference

#include <include/EDoc/Dictionary.h>


Detailed Description

Represents one or more merged translation units.

The Dictionary class is the main class of the system. Dictionary objects have 1:1 mappings with .edc files. You will read a .edc file into a dictionary instance or write one from a Dictionary instance.

Most objects belong to a specific dictionary. This is important for correct memory management. It is not possible to assign pointers to DictionarySpecific objects between different dictionary instances.

The main object types directly stored in a Dictionary include:

These above object types are specially managed. In order to simplify the memory allocation and handling of these objects, we have made them all derive from the StringIdentifiedObject class. Each of these objects is identified by a unique string. For example a Function is identified by the string for the name used as its link name which you would see using nm on a binary file.

It is helpful to note that while these objects are all identified by unique string keys, in the .edc files they are identified by integer indexes. This makes the loading procedure become a two stage procedure and the IndexedDictionary is used to perform the initial load using indexes. Using integer indexes in the .edc files was done to decrease loading/saving times and to decrease file size. See Read() and Write() for more information.

Most objects in EDoc are DictionarySpecific objects. This means that they are associated with a particular dictionary. These object can NOT be referenced from objects within a different dictionary but must be duplicated to the other dictionary first before they can be referenced by any objects in the other dictionary. This can often be achieved using code like follows:

    void Func(Type* other_dict_type)
    {
       // Will retrieve or create the type from this dictionary with the
       // same string identifier as the type from the other dictionary.
       // However the type will be "empty" if it did not exist in this
       // dictionary to start with.
       Type* this_dict_type = this_dict.types.AlwaysGet(*other_dict_type);
    }

If the type is not complete then its IsPopulated() will return false. In which case you will need to populate it using the assignment operator or some other means. Also note however that when populating it the type may also referr to other "un-populated" objects that you will need to populate.

As you can see it is not easy to move or copy objects from one dictionary to another. Most usages of the EDoc however will not require the user to do anything like this anyhow as all the assigning/merging etc is done by the procedure of:

dict1.Read(...); dict2.Read(...); dict1.Merge(dict2);

This will read two .edc files into two seperate dictionaries, and then "merge" the two dictionaries. A merge is kind of like linking objects/libraries together in the development of an application.

Temporary Dictionary Staging Area

When using the EDoc python module, you will probably make use of the temporary dictionary staging area. This is a static pointer to a "current" working dictionary. This will generally be used for communication between the python and C++ code. In particular the python wrappers require the use of a default constructor for most data types due to a limitation (OR I JUST DONT KNOW HOW TO USE IT PROPERLY YET) of Swig. Since most objects require that the dictionary that they will belong to be passed upon construction time, this means that there is no real possibility of having a default constructor. Instead now, if the default constructor is used, all DictionarySpecific objects will use the dictionary that can be currently retrieved using GetCurrentDictionaryAssert()

See GetCurrentDictionary() for more details.

Definition at line 139 of file Dictionary.h.

Public Member Functions

 Dictionary ()
 Constructor.
 ~Dictionary ()
 Erases all memory for all objects that are specific to this dictionary.
void Read (PersistenceIFace &file)
 Reads the contents of a .edc file into this dictionary instance.
void Write (PersistenceIFace &file) const
 Writes the contents of this dictionary to a .edc file.
void Merge (const Dictionary &right)
 Merges the contents of another dictionary into this dictionary.
size_t ReplaceReferences (PStack &stack, void *remove, void *replace)
 Replaces all references of pointer remove with pointer replace.
std::ostream & Print (std::ostream &out, std::string prefix="") const
 Prints the contents of this object to the given stream in a user readable manner.
std::string ToString (std::string prefix="") const
 Returns a string with the same contents as would be displayed by the Print() function.
void Validate () const
 Performs internal validation of the Dictionary object and all its data.
void ExpandCallGraph ()
 Expands FunctionPointer calls and Virtual function calls into a list of "possible" function calls.
void ErasePropogatingExceptions ()
 Erases all propogating exception data from all functions.
void CalculateCallComplexity (std::vector< Function * > &funcs)
 Analyses the callgraph of all functions ordering them by complexity and marking circular callgraphs.
void CalculatePropogatingExceptions (std::vector< Function * > &sorted, FunctionProgressIFace *progress=NULL)
 Calculates the propogating exceptions for all functions provided in the vector sorted which must be in order of the call complexity.
TranslationUnitGetIndexedTranslationUnit (int32_t index)
 Returns the translation unit with the given index.
int32_t GetTranslationUnitIndex (TranslationUnit *tu)
 Returns the index of the provided translation unit.
std::list< ManagedObjectPtrGetManagedObjects ()
 Returns a list containing a reference to the ManagedObject types being managed by this dictionary.
std::vector< ManagedObjectPtrGetManagedObjectsVector ()
 See GetManagedObjects().
std::vector< const ManagedObject * > GetManagedObjectsVector () const
 See GetManagedObjects().

Data Fields

const FileUNKNOWN_FILE
 Every dictionary contains an "Unknown File" pointer that is used for source files we could not determine.
const LocationUNKNOWN_LOCATION
 Every dictionary contains an "Unknown File" pointer that is used for source locations we could not determine in the GCC MOD.
const TypeSUBSTITUTION_EXCEPTION_TYPE
 Substitution exceptions type.
SpecificManagedObject< Filefiles
SpecificManagedObject< Typetypes
SpecificManagedObject< FunctionTypefunction_types
SpecificManagedObject< Functionfunctions
std::vector< TranslationUnit * > translation_units
 A vector of all translation units that have been merged into this dictionary.

Protected Member Functions

void EraseAll ()
 Erases all data associated with this dictionary instance.
void GeneratePredefined ()
 Generates default set of data required by all dictionaries.
bool GenerateExceptions (FunctionProgressIFace *progress, Function &function)
 Process the given function and functions it calls to generate the list of exceptions that may be emitted by it.
void HandleCircularCallgraph (FunctionProgressIFace *progress, Function &function)
 Handles the special case of a circular callgraph when calculating propogating exceptions for a function.
void PostProcessExceptions (Function &function)
 After the complete list of propogating exceptions has been calculated, this will filter out those exceptions that will not be emitted as a result of the functions throw() specifier while emitting any warnings for such cases.
void ProcessFunction (Function &top, FunctionLoc &function, std::list< PropogatingException > &poss_curr_catch_types)
 For internal use in calculating propogating exceptions.
void ProcessCodeBlock (Function &top, CodeBlock &block, FunctionLoc &function, std::list< PropogatingException > &poss_curr_catch_types, std::list< PropogatingException > &exceptions)
 For internal use in calculating propogating exceptions.
void ProcessTryBlock (Function &top, TryBlock &block, FunctionLoc &function, std::list< PropogatingException > &poss_curr_catch_types, std::list< PropogatingException > &exceptions)
 For internal use in calculating propogating exceptions.
void UpdateFunctionAddressLists ()
 For internal use in ExpandCallgraph().


Constructor & Destructor Documentation

EDoc::Dictionary::Dictionary (  ) 

Constructor.

Note: Will create a single File object called UNKNOWN_FILE and also a single location object called UNKNOWN_LOCATION. These will exist in all dictionaries.

Definition at line 349 of file Dictionary.cpp.

References GeneratePredefined().

EDoc::Dictionary::~Dictionary (  ) 

Erases all memory for all objects that are specific to this dictionary.

This will erase all DictionarySpecific objects owned by this dictionary.

Definition at line 362 of file Dictionary.cpp.

References EraseAll().


Member Function Documentation

EDoc::Dictionary::Read ( PersistenceIFace file  ) 

Reads the contents of a .edc file into this dictionary instance.

This will replace the contents of this dictionary with the contents of the .edc file. All old state of this dictionary will be lost.

The process of reading .edc files is quite involved. It is mostly made so by certain limitations placed on it by the GCC modification and also due to the design decision of storing references to objects in the .edc file using integer indexes instead of string keys as are using in the runtime objects.

When a read operation occurs the following sequence is followed:

  1. Erase all current data from the dictionary.
  2. Construct an Indexed dictionary used to associate integer index references with object instances.
  3. Read the contents of the .edc file header. This includes info like translation units referenced in .edc file, version information etc.
  4. Read all data records.
  5. Validate that all read data objects have been inserted into the dictionary.
The IndexedDictionary is used to associated particular instances with indexes as they are read from the file.

reading of data objects occurs in a a set number of stages. These stages correspond to the indexes of items in the managed objects vector. I.e.

  1. Stage 0: File objects : GetManagedObjectsVector() index 0
  2. Stage 1: Type objects : GetManagedObjectsVector() index 1
  3. Stage 2: FunctionType objects : GetManagedObjectsVector() index 2
  4. Stage 3: Function objects : GetManagedObjectsVector() index 3
Doing the stages this way GREATLY simplifies the reading code as it is the same for each data object type except the index to the vector changes as you move from one stage to the next.

This places the requirement on the .edc files that all items must be saved to the file in the given order: File, Type, FunctionType, Function

Definition at line 434 of file Dictionary.cpp.

References EDoc::TranslationUnit::Create(), EDOC_ASSERT, EDOC_Debug, EDOC_FILE_VERSION, EDOC_Fine, EDOC_Finer, EDOC_FOREACH, EDOC_THROW_EXCEPTION, EraseAll(), GeneratePredefined(), EDoc::StringIdentifiedObject::GetKeyName(), EDoc::IndexedDictionary::GetManagedObjects(), GetManagedObjectsVector(), EDoc::StringIdentifiedObject::IsPopulated(), KEY_EDOC_VERSION, KEY_INDEX, KEY_TRANSLATION_UNIT, KEY_TRANSLATION_UNITS_LS, EDoc::StringIdentifiedObject::Read(), EDoc::PersistenceIFace::ReadRecordType(), EDoc::PersistenceIFace::ReadString(), EDoc::PersistenceIFace::ReadUInt32(), EDoc::PersistenceIFace::ReadUInt8(), ReplaceReferences(), EDoc::DictionarySpecific::ToString(), translation_units, Validate(), VALUE_RECORD_TYPE_FILE, VALUE_RECORD_TYPE_FUNCTION, VALUE_RECORD_TYPE_FUNCTION_TYPE, VALUE_RECORD_TYPE_HEADER, and VALUE_RECORD_TYPE_TYPE.

EDoc::Dictionary::Write ( PersistenceIFace file  )  const

Writes the contents of this dictionary to a .edc file.

Writing is a simple task in comparison to reading. It simply assigns an integer index to each object before writing. Writes all objects and then resets the integer indexes to -1.

Definition at line 664 of file Dictionary.cpp.

References EDOC_FILE_VERSION, EDOC_Finer, EDOC_FOREACH_CONST, GetManagedObjectsVector(), KEY_EDOC_VERSION, KEY_INDEX, KEY_TRANSLATION_UNIT, KEY_TRANSLATION_UNITS_LS, SUBSTITUTION_EXCEPTION_TYPE, translation_units, VALUE_RECORD_TYPE_HEADER, EDoc::PersistenceIFace::WriteRecordType(), EDoc::PersistenceIFace::WriteString(), EDoc::PersistenceIFace::WriteUInt32(), and EDoc::PersistenceIFace::WriteUInt8().

EDoc::Dictionary::Merge ( const Dictionary right  ) 

Merges the contents of another dictionary into this dictionary.

This is similar to linking objects together. It will resolve calls to un-implemented functions with the correct implementations from other translation units. It will produce errors if multiple implementations are found of a single function (If they are different so we dont emit errors for "vaguely" linked functions).

The result is a modified Dictionary that is the union of the two.

Definition at line 593 of file Dictionary.cpp.

References EDOC_ASSERT, EDOC_Finer, EDOC_FOREACH_CONST, GetManagedObjectsVector(), EDoc::PushBackUnique(), translation_units, and Validate().

EDoc::Dictionary::ReplaceReferences ( PStack stack,
void *  remove,
void *  replace 
)

Replaces all references of pointer remove with pointer replace.

This is used during the loading process to remove duplicate objects from all dictionary specific objects and replace them with a single "reference" object. After calling this function the user can be guarenteed that this object will no longer contain any references to "remove".

When used on a dictionary this will attempt to replace all references to the pointer remove over the entire Dictionary instance andall its children.

Parameters:
stack Is a processing stack used to ensure that recursive associations do not form endless loops of replacing.
remove Is a pointer value that we wish to replace.
replace Is a pointer value to replace all instances of remove with.
Returns:
Returns the number of occurences of remove that were replaced with replace.

Definition at line 1598 of file Dictionary.cpp.

References EDOC_FOREACH_CONST, EDOC_REPLACE, GetManagedObjectsVector(), EDoc::PStack::Push(), and UNKNOWN_FILE.

Referenced by Read().

EDoc::Dictionary::Print ( std::ostream &  out,
std::string  prefix = "" 
) const

Prints the contents of this object to the given stream in a user readable manner.

Parameters:
out The output stream to print to.
prefix A prefix to print before every line displayed. Usually used to provide indenting when printing a heirarchy of objects.

Definition at line 646 of file Dictionary.cpp.

References GetManagedObjectsVector().

Referenced by std::operator<<(), and ToString().

EDoc::Dictionary::ToString ( std::string  prefix = ""  )  const

Returns a string with the same contents as would be displayed by the Print() function.

Note:
EDoc++ data included.

Definition at line 657 of file Dictionary.cpp.

References Print().

EDoc::Dictionary::Validate (  )  const

Performs internal validation of the Dictionary object and all its data.

This will raise a BugException if internal validation fails andshould only be used for debugging purposes. It is quite slow.

Definition at line 624 of file Dictionary.cpp.

References EDOC_ASSERT, files, EDoc::StringIdentifiedObject::GetKeyName(), GetManagedObjectsVector(), UNKNOWN_FILE, and UNKNOWN_LOCATION.

Referenced by CalculatePropogatingExceptions(), ExpandCallGraph(), Merge(), and Read().

EDoc::Dictionary::ExpandCallGraph (  ) 

Expands FunctionPointer calls and Virtual function calls into a list of "possible" function calls.

This results in a "more than complete" call-graph.

See also:
See CalculatePropogatingExceptions() for information about this group of functions.

Definition at line 728 of file Dictionary.cpp.

References EDOC_FOREACH, functions, UpdateFunctionAddressLists(), and Validate().

EDoc::Dictionary::ErasePropogatingExceptions (  ) 

Erases all propogating exception data from all functions.

This must be called before calculating the propogating exception information to ensure it starts with a clean slate.

See also:
See CalculatePropogatingExceptions() for information about this group of functions.

Definition at line 953 of file Dictionary.cpp.

References EDOC_FOREACH, EDoc::Erase(), and functions.

EDoc::Dictionary::CalculateCallComplexity ( std::vector< Function * > &  funcs  ) 

Analyses the callgraph of all functions ordering them by complexity and marking circular callgraphs.

This will mark the complexity of a function by setting: Function::total_calls to the number of unique functions called. It will also identify circular callgraphs between a group of functions and if such exists will create the member: Function::circular with a set of the functions in the circular graph.

Finally it will return a vector of all the functions sorted in order of their Function::total_calls member. This is used to process the functions in order when calculating the propogating exceptions In particular it is dynamic programming in action. By calculating the least complex functions first, they are then available to be used in the more complex functions later. I.e. The processing the functions in this order means that we dont need to "re-calculate" information.

See also:
See CalculatePropogatingExceptions() for information about this group of functions.

Definition at line 980 of file Dictionary.cpp.

References EDoc::CalculateTotalFunctionCalls(), EDOC_Debug, EDOC_Fine, EDOC_FOREACH, functions, and EDoc::LessThanCallComplexity().

EDoc::Dictionary::CalculatePropogatingExceptions ( std::vector< Function * > &  sorted,
FunctionProgressIFace progress = NULL 
)

Calculates the propogating exceptions for all functions provided in the vector sorted which must be in order of the call complexity.

This function asserts that the vector is provided in the correct order.

To calculate the propogating exceptions for a dictionary the following functions must be called in order:

  1. ExpandCallGraph()
  2. ErasePropogatingExceptions()
  3. CalculateCallComplexity()
  4. CalculatePropogatingExceptions()
This function makes use of:
Todo:
Document the algorithm used for this operation.

Definition at line 1016 of file Dictionary.cpp.

References EDOC_Fine, GenerateExceptions(), HandleCircularCallgraph(), PostProcessExceptions(), EDoc::ProgressIFace< T >::Start(), and Validate().

EDoc::Dictionary::GetIndexedTranslationUnit ( int32_t  index  ) 

Returns the translation unit with the given index.

Note:
EDoc++ data included.

Definition at line 1623 of file Dictionary.cpp.

References EDoc::TranslationUnit::GetUnknown(), and translation_units.

Referenced by EDoc::Type::Read(), and EDoc::Function::Read().

EDoc::Dictionary::GetTranslationUnitIndex ( TranslationUnit tu  ) 

Returns the index of the provided translation unit.

NOTE: Will throw a BugException if the translation unit is not in this dictionaries list of translation units.

Definition at line 1632 of file Dictionary.cpp.

References EDOC_ASSERT, EDoc::TranslationUnit::GetUnknown(), and translation_units.

Referenced by EDoc::Type::Write(), and EDoc::Function::Write().

EDoc::Dictionary::GetManagedObjects (  )  [inline]

Returns a list containing a reference to the ManagedObject types being managed by this dictionary.

This includes all File, Type, FunctionType and Function instances.

Definition at line 384 of file Dictionary.h.

References files, function_types, functions, and types.

Referenced by EraseAll().

EDoc::Dictionary::GetManagedObjectsVector (  )  [inline]

See GetManagedObjects().

Note:
EDoc++ data included.

Definition at line 399 of file Dictionary.h.

References files, function_types, functions, and types.

Referenced by Merge(), Print(), Read(), ReplaceReferences(), Validate(), and Write().

EDoc::Dictionary::GetManagedObjectsVector (  )  const [inline]

See GetManagedObjects().

Note:
EDoc++ data included.

Definition at line 414 of file Dictionary.h.

References files, function_types, functions, and types.

EDoc::Dictionary::EraseAll (  )  [protected]

Erases all data associated with this dictionary instance.

Note:
EDoc++ data included.

Definition at line 368 of file Dictionary.cpp.

References EDOC_FOREACH, GetManagedObjects(), SUBSTITUTION_EXCEPTION_TYPE, UNKNOWN_FILE, and UNKNOWN_LOCATION.

Referenced by Read(), and ~Dictionary().

EDoc::Dictionary::GeneratePredefined (  )  [protected]

Generates default set of data required by all dictionaries.

Note:
EDoc++ data included.

Definition at line 386 of file Dictionary.cpp.

References EDoc::Type::external_linkage, files, EDoc::TranslationUnit::GetUnknown(), EDoc::StringIdentifiedObject::index, EDoc::StringIdentifiedObject::IsPopulated(), EDoc::StringIdentifiedObject::key_name, EDoc::Type::loc, EDoc::Type::name, EDoc::StringIdentifiedObject::populated, EDoc::Type::referenced_in_files, EDoc::Type::root_type, SUBSTITUTION_EXCEPTION_TYPE, EDoc::Type::throw_type, EDoc::Type::translation_unit, types, UNKNOWN_FILE, UNKNOWN_LOCATION, and EDoc::Type::visible.

Referenced by Dictionary(), and Read().

EDoc::Dictionary::GenerateExceptions ( FunctionProgressIFace progress,
Function function 
) [protected]

Process the given function and functions it calls to generate the list of exceptions that may be emitted by it.

This does not return a completed list of propogating exceptions in the case where the function participates in a circular callgraph. In this case the list of exceptions will include one or more exceptions with type: SUBSTITUTION_EXCEPTION_TYPE and the function will return a boolean value of true.

In the case of the function participating in a circular callgraph, only the first function in that callgraph should return a value of true.

Returns:
Returns a value of true if this function was part of a circular callgraph AND additional processing needs to be performed on this function (and the others in the callgraph) by the HandleCircularCallgraph) function. I.e. If this function returns true then you must also call HandleCircularCallgraph().

Definition at line 1066 of file Dictionary.cpp.

References EDoc::Function::calculated_propogating_exceptions, EDoc::Function::circular, EDOC_Finer, EDoc::FunctionLoc::is_top_level, ProcessFunction(), EDoc::ProgressIFace< T >::Progress(), and UNKNOWN_LOCATION.

Referenced by CalculatePropogatingExceptions(), and HandleCircularCallgraph().

EDoc::Dictionary::HandleCircularCallgraph ( FunctionProgressIFace progress,
Function function 
) [protected]

Handles the special case of a circular callgraph when calculating propogating exceptions for a function.

This will ensure that GenerateExceptions() has been called for all functions in the circular callgraph. Following this it will then find the union of all exceptions thrown by those functions and then will substitute that unioned list of exceptions for all exceptions of that have the type: SUBSTITUTION_EXCEPTION_TYPE.

Definition at line 1105 of file Dictionary.cpp.

References EDoc::AddExceptions(), EDoc::Function::circular, EDOC_ASSERT, EDOC_FOREACH, EDoc::PropogatingException::exception, GenerateExceptions(), EDoc::PropogatingException::possible, EDoc::PushBackUnique(), SUBSTITUTION_EXCEPTION_TYPE, and EDoc::PropogatingException::visible.

Referenced by CalculatePropogatingExceptions().

EDoc::Dictionary::PostProcessExceptions ( EDoc::Function function  )  [protected]

After the complete list of propogating exceptions has been calculated, this will filter out those exceptions that will not be emitted as a result of the functions throw() specifier while emitting any warnings for such cases.

Note:
EDoc++ data included.

Definition at line 1211 of file Dictionary.cpp.

References EDOC_Debug, EDOC_FOREACH, EDoc::Function::exception_spec, EDoc::Function::filtered_exceptions, EDoc::Function::has_exception_spec, and EDoc::Function::propogating_exceptions.

Referenced by CalculatePropogatingExceptions().

EDoc::Dictionary::ProcessFunction ( EDoc::Function top,
EDoc::FunctionLoc function,
std::list< PropogatingException > &  poss_curr_catch_types 
) [protected]

For internal use in calculating propogating exceptions.

Note:
EDoc++ data included.

Definition at line 1261 of file Dictionary.cpp.

References EDoc::Function::calculated_propogating_exceptions, EDoc::Function::circular, EDoc::Function::derived_virtuals, EDOC_ASSERT, EDOC_Debug, EDOC_Fine, EDOC_Finer, EDOC_FOREACH_CONST, EDoc::Erase(), EDoc::Function::filtered_exceptions, EDoc::Function::GetDeclaredName(), EDoc::StringIdentifiedObject::GetKeyName(), EDoc::Function::GetSubstException(), EDoc::Function::implementation, EDoc::FunctionLoc::is_top_level, ProcessCodeBlock(), EDoc::Function::processed_implementations, EDoc::Function::propogating_exceptions, SUBSTITUTION_EXCEPTION_TYPE, UNKNOWN_LOCATION, and EDoc::FunctionLoc::value.

Referenced by GenerateExceptions(), and ProcessCodeBlock().

EDoc::Dictionary::ProcessCodeBlock ( EDoc::Function top,
EDoc::CodeBlock block,
EDoc::FunctionLoc function,
std::list< PropogatingException > &  poss_curr_catch_types,
std::list< PropogatingException > &  exceptions 
) [protected]

For internal use in calculating propogating exceptions.

Note:
EDoc++ data included.

Definition at line 1361 of file Dictionary.cpp.

References EDoc::AddOException(), EDoc::AddPException(), EDoc::CodeBlock::AllFunctionCalls(), EDOC_Fine, EDOC_Finer, EDOC_FOREACH, EDOC_NOTIFICATION, EDoc::Location::file, EDoc::Function::GetDeclaredName(), EDoc::StringIdentifiedObject::GetKeyName(), EDoc::Location::line, EDoc::FunctionLoc::loc, EDoc::CodeBlock::originating_exceptions, ProcessFunction(), ProcessTryBlock(), EDoc::CodeBlock::try_blocks, EDoc::FunctionLoc::value, and EDoc::WSET_UNEXPECTED.

Referenced by ProcessFunction(), and ProcessTryBlock().

EDoc::Dictionary::ProcessTryBlock ( EDoc::Function top,
EDoc::TryBlock block,
EDoc::FunctionLoc function,
std::list< PropogatingException > &  poss_curr_catch_types,
std::list< PropogatingException > &  exceptions 
) [protected]

For internal use in calculating propogating exceptions.

Note:
EDoc++ data included.

Definition at line 1446 of file Dictionary.cpp.

References EDoc::AddExceptions(), EDoc::TryBlock::catch_blocks, EDOC_Fine, EDOC_Finer, EDOC_FOREACH, EDOC_NOTIFICATION, EDoc::ENOT_THROW, EDoc::Location::file, EDoc::Function::GetDeclaredName(), EDoc::FunctionLoc::is_top_level, EDoc::Location::line, EDoc::Function::loc, EDoc::FunctionLoc::loc, ProcessCodeBlock(), SUBSTITUTION_EXCEPTION_TYPE, EDoc::TryBlock::try_block, EDoc::FunctionLoc::value, and EDoc::WUNUSED_CATCH.

Referenced by ProcessCodeBlock().

EDoc::Dictionary::UpdateFunctionAddressLists (  )  [protected]

For internal use in ExpandCallgraph().

Note:
EDoc++ data included.

Definition at line 746 of file Dictionary.cpp.

References EDoc::Function::address_taken, EDOC_Fine, EDOC_FOREACH, EDoc::FunctionType::equivilant, EDoc::Erase(), EDoc::Function::function_pointer_type, function_types, functions, EDoc::StringIdentifiedObject::GetKeyName(), and EDoc::PushBackUnique().

Referenced by ExpandCallGraph().


Field Documentation

const File* EDoc::Dictionary::UNKNOWN_FILE

Every dictionary contains an "Unknown File" pointer that is used for source files we could not determine.

Definition at line 437 of file Dictionary.h.

Referenced by EraseAll(), GeneratePredefined(), ReplaceReferences(), and Validate().

const Location* EDoc::Dictionary::UNKNOWN_LOCATION

Every dictionary contains an "Unknown File" pointer that is used for source locations we could not determine in the GCC MOD.

Definition at line 443 of file Dictionary.h.

Referenced by EDoc::AddOException(), EraseAll(), EDoc::Function::ExpandCallGraph(), GenerateExceptions(), GeneratePredefined(), EDoc::Function::GetSubstException(), ProcessFunction(), and Validate().

const Type* EDoc::Dictionary::SUBSTITUTION_EXCEPTION_TYPE

Substitution exceptions type.

Definition at line 448 of file Dictionary.h.

Referenced by EraseAll(), GeneratePredefined(), EDoc::Function::GetSubstException(), HandleCircularCallgraph(), ProcessFunction(), ProcessTryBlock(), and Write().

SpecificManagedObject<File> EDoc::Dictionary::files

Definition at line 450 of file Dictionary.h.

Referenced by GeneratePredefined(), GetManagedObjects(), GetManagedObjectsVector(), EDoc::Location::Location(), EDoc::Type::Merge(), EDoc::Location::Merge(), EDoc::Function::Merge(), EDoc::Type::operator=(), EDoc::Location::operator=(), EDoc::Function::operator=(), EDoc::File::Validate(), and Validate().

SpecificManagedObject<Type> EDoc::Dictionary::types

Definition at line 451 of file Dictionary.h.

Referenced by GeneratePredefined(), GetManagedObjects(), GetManagedObjectsVector(), EDoc::Type::Merge(), EDoc::TypeLoc::operator=(), EDoc::Type::operator=(), EDoc::FunctionType::operator=(), EDoc::Function::operator=(), EDoc::TypeLoc::TypeLoc(), and EDoc::Type::Validate().

SpecificManagedObject<FunctionType> EDoc::Dictionary::function_types

Definition at line 452 of file Dictionary.h.

Referenced by EDoc::FunctionTypeLoc::FunctionTypeLoc(), GetManagedObjects(), GetManagedObjectsVector(), EDoc::Function::Merge(), EDoc::FunctionTypeLoc::operator=(), EDoc::Function::operator=(), UpdateFunctionAddressLists(), and EDoc::FunctionType::Validate().

SpecificManagedObject<Function> EDoc::Dictionary::functions

Definition at line 453 of file Dictionary.h.

Referenced by CalculateCallComplexity(), ErasePropogatingExceptions(), EDoc::Exception::Exception(), ExpandCallGraph(), EDoc::FunctionLoc::FunctionLoc(), GetManagedObjects(), GetManagedObjectsVector(), EDoc::Function::Merge(), EDoc::FunctionLoc::operator=(), EDoc::Function::operator=(), EDoc::Exception::operator=(), UpdateFunctionAddressLists(), and EDoc::Function::Validate().

std::vector<TranslationUnit*> EDoc::Dictionary::translation_units

A vector of all translation units that have been merged into this dictionary.

Definition at line 459 of file Dictionary.h.

Referenced by GetIndexedTranslationUnit(), GetTranslationUnitIndex(), Merge(), Read(), and Write().


The documentation for this class was generated from the following files:
Generated on Tue Jan 20 18:26:08 2009 for EDoc-0.2.1 by  doxygen 1.5.1