Skip to content
Snippets Groups Projects
Commit 70193c92 authored by Sébastien Villemot's avatar Sébastien Villemot
Browse files

Remove spurious display when there is zero preprocessor warning

parent 8ba4a3a4
Branches
No related tags found
No related merge requests found
......@@ -640,8 +640,10 @@ ModFile::writeOutputFiles(const string &basename, bool clear_all, bool no_log, b
if (!no_warn)
{
mOutputFile << "disp('Note: " << warnings.countWarnings() << " warning(s) encountered in the preprocessor')" << endl
<< "if ~isempty(lastwarn)" << endl
if (warnings.countWarnings() > 0)
mOutputFile << "disp('Note: " << warnings.countWarnings() << " warning(s) encountered in the preprocessor')" << endl;
mOutputFile << "if ~isempty(lastwarn)" << endl
<< " disp('Note: warning(s) encountered in MATLAB/Octave code')" << endl
<< "end" << endl;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment