azmfaridee / mothur

This is GSoC2012 fork of 'Mothur'. We are trying to implement a number of 'Feature Selection' algorithms for microbial ecology data and incorporate them into mother's main codebase.
https://github.com/mothur/mothur
GNU General Public License v3.0
3 stars 1 forks source link

Replace Normal Debug Messages in C++ implementation with MothurOut Code #28

Closed azmfaridee closed 11 years ago

azmfaridee commented 11 years ago

The file macros.h has a lot of debugging macros defined, they are defined for standard cout, we need to make them work with mothur's MothurOut class

azmfaridee commented 11 years ago

Some macros like

#define PRINT_VAR(X) (cout << #X << " -> " << X << endl)

are pretty difficult to convert to MothurOut code as as the macro uses hash token to convert a variable's names to a string, we need to find alternate ways to implement this

mothur-westcott commented 11 years ago

The mothur.h header has several toString functions. Can you use one of those? Something like: m->mothurOut(toString(X)); m->mothurOutEndLine();