#include "idep_linkdep.h"#include "idep_namearray.h"#include "idep_nameindexmap.h"#include "idep_binrel.h"#include "idep_string.h"#include "idep_tokeniter.h"#include "idep_aliastable.h"#include "idep_aliasutil.h"#include <cmath>#include <ctype.h>#include <cstring>#include <memory>#include <fstream>#include <sstream>#include <iostream>#include <cassert>Go to the source code of this file.
Classes | |
| struct | idep_LinkDep_i |
| struct | idep_AliasIter_i |
| struct | idep_UnaliasIter_i |
| struct | idep_CycleIter_i |
| struct | idep_MemberIter_i |
| struct | idep_LevelIter_i |
| struct | idep_ComponentIter_i |
| struct | idep_DependencyIter_i |
Typedefs | |
| typedef int | FmtFlags_t |
Functions | |
| std::ostream & | warn (std::ostream &ing, int index) |
| std::ostream & | err (std::ostream &orr) |
| const char * | stripDotSlash (const char *originalPath) |
| int | isLocal (const char *dirFile) |
| char * | removeFileName (char *dirPath) |
| char * | removeSuffix (char *dirPath) |
| int | digits (int n) |
| double | logBase2 (double x) |
| double | ccdBalencedBinaryTree (int n) |
| const char * | s (int n) |
| std::ostream & | operator<< (std::ostream &o, const idep_LinkDep &dep) |
|
|
Definition at line 26 of file idep_ldep.cxx. Referenced by idep_LinkDep::printLevels(), and idep_LinkDep::printSummary(). |
|
|
Definition at line 100 of file idep_ldep.cxx. References logBase2(). Referenced by idep_LinkDep::nccd(). 00101 {
00102 // CCD(n) = (n + 1) * (log (n + 1) - 1) + 1
00103 // balanced 2
00104 // binary
00105 // tree
00106
00107 assert(n >= 0);
00108 return (n + 1) * (logBase2(n + 1) - 1) + 1;
00109 }
|
|
|
Definition at line 79 of file idep_ldep.cxx. Referenced by idep_LinkDep::printLevels(), AlgChopListSharp2::RunAlg(), AlgChopListSharp::RunAlg(), AlgChopListPerfectMC::RunAlg(), AlgChopListMitre::RunAlg(), AlgChopListGeneric::RunAlg(), and AlgChopListFar::RunAlg(). 00080 {
00081 int fieldWidth = 10;
00082 assert (sizeof (long int) >= 4);
00083 long int x = 1000 * 1000 * 1000; // requires 4-byte integer.
00084 while (fieldWidth > 1 && 0 == n / x) {
00085 --fieldWidth;
00086 x /= 10;
00087 }
00088 return fieldWidth;
00089 }
|
|
|
Definition at line 38 of file idep_ldep.cxx. 00039 {
00040 return orr << "Error: ";
00041 }
|
|
|
Definition at line 53 of file idep_ldep.cxx. Referenced by idep_LinkDep_i::entry(). 00054 {
00055 return !strchr(dirFile, '/');
00056 }
|
|
|
Definition at line 91 of file idep_ldep.cxx. Referenced by ccdBalencedBinaryTree(). 00092 {
00093 // log (x) = ln(x)/ln(a)
00094 // a
00095
00096 assert(x > 0.0);
00097 return log(x)/log(2);
00098 }
|
|
||||||||||||
|
Definition at line 1110 of file idep_ldep.cxx. 01111 {
01112 dep.printAliases(o);
01113 dep.printUnaliases(o);
01114 dep.printCycles(o);
01115 dep.printLevels(o, 1);
01116 dep.printSummary(o);
01117 return o;
01118 }
|
|
|
Definition at line 58 of file idep_ldep.cxx. Referenced by idep_LinkDep_i::entry(). 00059 {
00060 char *slash = strrchr(dirPath, '/');
00061 if (slash) {
00062 slash[1] = '\0';
00063 }
00064 else {
00065 dirPath[0] = '\0';
00066 }
00067 return dirPath;
00068 }
|
|
|
Definition at line 70 of file idep_ldep.cxx. Referenced by idep_LinkDep_i::entry(), idep_AliasDep::extract(), idep_AliasDep::unpaired(), and idep_AliasDep::verify(). 00071 {
00072 char *dot = strrchr(dirPath, '.');
00073 if (dot && !strchr(dot, '/')) {
00074 dot[0] = '\0';
00075 }
00076 return dirPath;
00077 }
|
|
|
|
Definition at line 43 of file idep_ldep.cxx. Referenced by idep_LinkDep::addUnaliasDirectory(), and search(). 00044 {
00045 if (originalPath) {
00046 while ('.' == originalPath[0] && '/' == originalPath[1]) {
00047 originalPath += 2;
00048 }
00049 }
00050 return originalPath;
00051 }
|
|
||||||||||||
|
Definition at line 33 of file idep_ldep.cxx. Referenced by idep_AliasDep::extract(), idep_LinkDep::printCycles(), and idep_AliasDep::unpaired(). 00034 {
00035 return ing << "Warning<" << index << ">: "; // '<' and '>' match cycle
00036 }
|
1.3.9.1