]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/CommandInset.cpp
Fix various warnings issued by clang++.
[lyx.git] / src / mathed / CommandInset.cpp
index c5448a21fc688ab89ad915a30385f5521a1d938e..0cf041c23ea7e59b2ec9fc62cf30690fca02cda5 100644 (file)
@@ -14,7 +14,6 @@
 #include "MathData.h"
 #include "MathStream.h"
 #include "DispatchResult.h"
-#include "FuncRequest.h"
 
 #include <sstream>
 
@@ -65,15 +64,12 @@ void CommandInset::draw(PainterInfo & pi, int x, int y) const
 
 void CommandInset::write(WriteStream & os) const
 {
-       ModeSpecifier specifier(os, currentMode(), lockedMode());
+       ModeSpecifier specifier(os, currentMode(), lockedMode(), asciiOnly());
        MathEnsurer ensurer(os, needs_math_mode_);
-       bool const ascii = os.asciiOnly();
-       os.asciiOnly(asciiOnly());
        os << '\\' << name_;
-       if (cell(1).size())
+       if (!cell(1).empty())
                os << '[' << cell(1) << ']';
        os << '{' << cell(0) << '}';
-       os.asciiOnly(ascii);
 }