Libraries: MQL Plus Enhanced Debugging Support - page 8

 
Dominik Egert #:
Lots of changes by MQ to the preprocessor made some macros break the code. This is one of the effects, but I have fixed that, will be in the next update.
thank you for your great work!
 
Hello, author. I have a function that prints logs centrally. In different places, I call this function and pass a string to it:  func1(string msg, ...); . Is it possible to implement a feature where  DBG_XXX  does not print but only returns the string? This way, when I call  func1 , I can record the location of the log.
 
hini #:
Hello, author. I have a function that prints logs centrally. In different places, I call this function and pass a string to it:  func1(string msg, ...); . Is it possible to implement a feature where  DBG_XXX  does not print but only returns the string? This way, when I call  func1 , I can record the location of the log.
Yes, actually this already exists.

You are looking at. DBG_MSG_VAR(). If you change this to DBG_STR_VAR() you will get the string instead.

All _MSG_ macros hava a complement with _STR_ such that you can get the string.

EDIT:
New update coming soon to this library.
 
Dominik Egert #:
Yes, actually this already exists.

You are looking at. DBG_MSG_VAR(). If you change this to DBG_STR_VAR() you will get the string instead.

All _MSG_ macros hava a complement with _STR_ such that you can get the string.

EDIT:
New update coming soon to this library.
grateful!
 
How soon will a new version be released? Please tell me if it is updated
 
hini #:
How soon will a new version be released? Please tell me if it is updated
I am still testing the current release candidate, and working on docs.... Hope to make it within the coming week.
 

Hello, how can I print the array variable after resizing the array?

ArrayResize(myArray, 10);

I use DBG_MSG_VAR_IF(Debug, myArray), and the array is out of bounds.

 
And can I print a two-dimensional array?
 
hini #:
And can I print a two-dimensional array?

In (unpublished) current version there is no bug. - Yes, you can print also multidimensional arrays.


    int arr[][2];
    ArrayResize(arr, 10);
    DBG_MSG_VAR_IF(true, arr);



 
hini #:
And can I print a two-dimensional array?

I have just uploaded the most recent version to CodeBase.