This file defines the cca program. More...
#include <cxxtls/cpp_token_stream.h>#include <cxxtls/file.h>#include <cxxtls/fmtd.h>#include <portable_math.h>#include <portable_strstream.h>#include <portable_io.h>#include <cxxtls/options.h>#include <cstdlib>#include <fstream>#include <iostream>#include <algorithm>#include <list>#include <memory.h>#include <iomanip>#include <set>
Go to the source code of this file.
Classes | |
| class | DefineHandler |
| This class exists so as to define an override of the virtual operator method(). Its behavior is to include #defines into the output data. More... | |
| struct | ElseifCounterInfo |
| class | FunctionScope |
| The name and information associated with a function's scope. More... | |
| struct | ScopeBinder |
| A ScopeBinder object is created to save and restore the value of the variable, outer_scope. You save the old one at construction of the ScopeBinder object. On its destruction, the old value is restored. More... | |
| struct | SummaryData |
Defines | |
| #define | ASSUMED_TOKEN(type) |
Functions | |
| static string | caseKeyWord ("case") |
| static string | catchKeyWord ("catch") |
| static string | classKeyWord ("class") |
| static string | constKeyWord ("const") |
| static string | defaultKeyWord ("default") |
| static string | doKeyWord ("do") |
| static void | eat_case_blocks () |
| static void | eat_curly_block () |
| static void | eat_function_body () |
| static void | eat_function_parms (string *parmtext=0) |
| static void | eat_parenthesis () |
| static void | eat_template_parms () |
| static void | eat_till_semicolon () |
| static void | eat_type_name () |
| static string | elseKeyWord ("else") |
| static string | enumKeyWord ("enum") |
| bool | eof () |
| static string | extendsKeyWord ("extends") |
| static string | externKeyWord ("extern") |
| static string | forKeyWord ("for") |
| static string | friendKeyWord ("friend") |
| static string | ifKeyWord ("if") |
| don't change this (except for debugging) | |
| static string | implementsKeyWord ("implements") |
| static void | log_symbol (string type, string name, string file, int line, bool include_scope=true) |
| int | main (int argc, char **argv, char **environ) |
| static string | namespaceKeyWord ("namespace") |
| static void | next_token () |
| static string | operatorKeyWord ("operator") |
| static bool | parse_class () |
| static bool | parse_declaration (bool log_func_forward_decls=false) |
| static void | parse_declarations (CPP_Buffer_Token_Source &s) |
| static bool | parse_enum () |
| static bool | parse_extern () |
| static void | parse_file (FileName const &) |
| static bool | parse_funcvar (bool log_forward_funcs_defs=false, bool handling_typedefs=false) |
| static bool | parse_namespace () |
| static bool | parse_typedef () |
| static bool | parse_using () |
| static void | parse_variables_defined (bool log_func_forward_decls=false, bool handling_typedefs=false) |
| static void | printInfo () |
| static void | printSummary () |
| static string | privateKeyWord ("private") |
| static bool | process_statement (ElseifCounterInfo *) |
| static string | protectedKeyWord ("protected") |
| static string | publicKeyWord ("public") |
| static string | returnKeyWord ("return") |
| static string | staticKeyWord ("static") |
| static string | structKeyWord ("struct") |
| static void | summarize () |
| static string | switchKeyWord ("switch") |
| static string | templateKeyWord ("template") |
| static string | throwKeyWord ("throw") |
| static string | tryKeyWord ("try") |
| static string | typedefKeyWord ("typedef") |
| static string | typenameKeyWord ("typename") |
| static string | unionKeyWord ("union") |
| static string | usingKeyWord ("using") |
| static string | whileKeyWord ("while") |
Variables | |
| static bool | collapse_elseif = true |
| don't change this | |
| static bool | collapse_return = true |
| collapse else-ifs to minimize CC number | |
| static bool | force_java_file = false |
| print data for all functions | |
| static bool | grep_style_output = true |
| print processed file names to stderr? | |
| static bool | isJavaFile = false |
| static bool | log_all_tokens_to_stderr = false |
| do names of files come from stdin? | |
| static bool | log_definitions = false |
| treat all input files as java (java processing is buggy!) | |
| static bool | log_filenames_to_stderr = false |
| copy tokens to stderr? | |
| FunctionScope | outer_scope |
| static ostreambuf_iterator < char > * | output |
| static bool | print_functions = true |
| print a summary at the end of execution | |
| static bool | print_summary = false |
| collapse return in else clauses to reduce CC number | |
| static bool | read_filenames_from_stdin = false |
| static set< string > | returnSynonyms |
| static CPP_Buffer_Token_Source * | stream |
| map< string, SummaryData > | summary |
| static CPP_Token | token |
This file defines the cca program.
Definition in file cca.cxx.
| #define ASSUMED_TOKEN | ( | type | ) |
| static string caseKeyWord | ( | "case" | ) | [static] |

| static string catchKeyWord | ( | "catch" | ) | [static] |

| static string classKeyWord | ( | "class" | ) | [static] |

| static string constKeyWord | ( | "const" | ) | [static] |

| static string defaultKeyWord | ( | "default" | ) | [static] |

| static string doKeyWord | ( | "do" | ) | [static] |

| static void eat_case_blocks | ( | ) | [static] |
| static void eat_curly_block | ( | ) | [static] |
| static void eat_function_body | ( | ) | [static] |
| static void eat_function_parms | ( | string * | parmtext = 0 |
) | [static] |
| static void eat_parenthesis | ( | ) | [static] |
| static void eat_template_parms | ( | ) | [static] |
| static void eat_till_semicolon | ( | ) | [static] |
| static void eat_type_name | ( | ) | [static] |
| static string elseKeyWord | ( | "else" | ) | [static] |

| static string enumKeyWord | ( | "enum" | ) | [static] |

| static string extendsKeyWord | ( | "extends" | ) | [static] |

| static string externKeyWord | ( | "extern" | ) | [static] |

| static string forKeyWord | ( | "for" | ) | [static] |

| static string friendKeyWord | ( | "friend" | ) | [static] |

| static string ifKeyWord | ( | "if" | ) | [static] |
don't change this (except for debugging)

| static string implementsKeyWord | ( | "implements" | ) | [static] |

| static void log_symbol | ( | string | type, | |
| string | name, | |||
| string | file, | |||
| int | line, | |||
| bool | include_scope = true | |||
| ) | [static] |
| int main | ( | int | argc, | |
| char ** | argv, | |||
| char ** | environ | |||
| ) |
| static string namespaceKeyWord | ( | "namespace" | ) | [static] |

| static void next_token | ( | ) | [static] |
| static string operatorKeyWord | ( | "operator" | ) | [static] |

| static bool parse_class | ( | ) | [static] |
| static bool parse_declaration | ( | bool | log_func_forward_decls = false |
) | [static] |
| static void parse_declarations | ( | CPP_Buffer_Token_Source & | s | ) | [static] |
| static bool parse_enum | ( | ) | [static] |
| static bool parse_extern | ( | ) | [static] |
| static void parse_file | ( | FileName const & | name | ) | [static] |
| static bool parse_funcvar | ( | bool | log_forward_funcs_defs = false, |
|
| bool | handling_typedefs = false | |||
| ) | [static] |
| static bool parse_namespace | ( | ) | [static] |
| static bool parse_typedef | ( | ) | [static] |
| static bool parse_using | ( | ) | [static] |
| static void parse_variables_defined | ( | bool | log_func_forward_decls = false, |
|
| bool | handling_typedefs = false | |||
| ) | [static] |
| static void printInfo | ( | ) | [static] |
| static void printSummary | ( | ) | [static] |
| static string privateKeyWord | ( | "private" | ) | [static] |

| static bool process_statement | ( | ElseifCounterInfo * | elseifCounter | ) | [static] |
| static string protectedKeyWord | ( | "protected" | ) | [static] |

| static string publicKeyWord | ( | "public" | ) | [static] |

| static string returnKeyWord | ( | "return" | ) | [static] |

| static string staticKeyWord | ( | "static" | ) | [static] |

| static string structKeyWord | ( | "struct" | ) | [static] |

| static void summarize | ( | ) | [static] |
| static string switchKeyWord | ( | "switch" | ) | [static] |

| static string templateKeyWord | ( | "template" | ) | [static] |

| static string throwKeyWord | ( | "throw" | ) | [static] |

| static string tryKeyWord | ( | "try" | ) | [static] |

| static string typedefKeyWord | ( | "typedef" | ) | [static] |

| static string typenameKeyWord | ( | "typename" | ) | [static] |

| static string unionKeyWord | ( | "union" | ) | [static] |

| static string usingKeyWord | ( | "using" | ) | [static] |

| static string whileKeyWord | ( | "while" | ) | [static] |

bool collapse_elseif = true [static] |
bool collapse_return = true [static] |
bool force_java_file = false [static] |
bool grep_style_output = true [static] |
bool isJavaFile = false [static] |
bool log_all_tokens_to_stderr = false [static] |
bool log_definitions = false [static] |
bool log_filenames_to_stderr = false [static] |
bool print_functions = true [static] |
bool print_summary = false [static] |
bool read_filenames_from_stdin = false [static] |
set<string> returnSynonyms [static] |
CPP_Buffer_Token_Source* stream [static] |
| map<string, SummaryData> summary |
1.6.3