-
Notifications
You must be signed in to change notification settings - Fork 82
Description
We would like your inputs on a couple of queries related to blitz usage.
It is very useful that Blitz supports printing any multidimensional arrays with a very simple statement as below
std::cout<<blitz_array_name<<std::endl
We are working on a large codebase, and we would like to print the array contents during the debug sessions as well.
We use GDB for debugging. We tried an option as below
a) overloaded functions for different type of arrays which we like to print, as below
void printBlitz(blitz::Array<bool, 1> &in)
{
std::cout<<in<<std::endl;
}
void printBlitz(blitz::Array<int, 1> &in)
{
std::cout<<in<<std::endl;
}
and so on
on the gdb debugger, we can simply call this function as below
(gdb) call printBlitz(blitz_array_name)
The issue now is we use many types of multi-dimensional arrays (including complex), we have to make overloads for every possible array
If you have any suggestions to directly print the blitz contents via GDB, please let us know.
This will simplify our debug to a large extent.
Any suggestion is highly appreciated
Thank you so much in advance !!