]> git.lyx.org Git - features.git/commitdiff
Fix warnings
authorRichard Kimberly Heck <rikiheck@lyx.org>
Tue, 17 Nov 2020 07:33:41 +0000 (02:33 -0500)
committerRichard Kimberly Heck <rikiheck@lyx.org>
Tue, 17 Nov 2020 07:33:41 +0000 (02:33 -0500)
src/mathed/MacroTable.cpp

index 8cf9273c54e89a75458152c335ae176d8fb68236..cfabd748d6fbc7f9e97446419371655fcd41e466 100644 (file)
@@ -139,7 +139,7 @@ docstring const MacroData::xmlname() const
 
 char const * MacroData::MathMLtype() const
 {
-       return sym_ ? sym_->MathMLtype() : 0;
+       return sym_ ? sym_->MathMLtype() : nullptr;
 }
 
 
@@ -195,7 +195,7 @@ int MacroData::write(odocstream & os, bool overwriteRedefinition) const
 
        // find macro template
        Inset * inset = pos_.nextInset();
-       if (inset == 0 || inset->lyxCode() != MATHMACRO_CODE) {
+       if (!inset || inset->lyxCode() != MATHMACRO_CODE) {
                lyxerr << "BUG: No macro template found by MacroData" << endl;
                return 0;
        }
@@ -225,7 +225,7 @@ GlobalMacros & GlobalMacros::get()
 MacroData const * GlobalMacros::getMacro(docstring const & name) const
 {
        const_iterator it = find(name);
-       return it == end() ? 0 : &it->second;
+       return it == end() ? nullptr : &it->second;
 }