openrave.org

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Functions
cpp-gen-md5.cpp File Reference

(2013-03-18 10:33:00 +0900, commit:334d202)

Generates a md5 hash from the lexical tokens of a C++ ignoring directives and whitespace. More...

#include "cpp_lexer.hpp"
#include <iostream>
#include <vector>
#include <sstream>
#include <cstdio>
#include <cstring>
#include "md5.h"
Include dependency graph for cpp-gen-md5.cpp:

Go to the source code of this file.

Functions

void getTokenData (const char *fname, vector< char > &vdata)
 
string getmd5hash (const char *fname, const vector< char > &vbasedata)
 
int main (int argc, char *argv[])
 

Detailed Description

Generates a md5 hash from the lexical tokens of a C++ ignoring directives and whitespace.

Author
Rosen Diankov Usage:
cpp-gen-md5 [filename1 define1] [filename2 define2] ...

If only a filename is given, will output a 16 byte string. If both filename and define are given will output a file consisting of the hashes:

#define @define2@ "@md5hash@"

Definition in file cpp-gen-md5.cpp.

Function Documentation

string getmd5hash ( const char *  fname,
const vector< char > &  vbasedata 
)

Definition at line 125 of file cpp-gen-md5.cpp.

void getTokenData ( const char *  fname,
vector< char > &  vdata 
)

Definition at line 68 of file cpp-gen-md5.cpp.

int main ( int  argc,
char *  argv[] 
)

Definition at line 32 of file cpp-gen-md5.cpp.