]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/MathAutoCorrect.cpp
Remove unused method in ArgumentProxy
[lyx.git] / src / mathed / MathAutoCorrect.cpp
index fcc9f7705af445c692303fa50f579f59956790ce..17431114b8c983e622e6890d3147b1f13d379dae 100644 (file)
@@ -35,6 +35,9 @@ namespace {
 class Correction {
 public:
        ///
+       /// \brief Correction
+       // it is fine not to initialize from2_
+       // coverity[UNINIT_CTOR]
        Correction() {}
        ///
        bool correct(MathAtom & at, char_type c) const;
@@ -72,13 +75,6 @@ bool Correction::read(idocstream & is)
 }
 
 
-void Correction::write(odocstream & os) const
-{
-       os << "from: '" << from1_ << "' and '" << from2_
-          << "' to '" << to_ << '\'' << endl;
-}
-
-
 bool Correction::correct(MathAtom & at, char_type c) const
 {
        //LYXERR(Debug::MATHED,
@@ -94,6 +90,14 @@ bool Correction::correct(MathAtom & at, char_type c) const
 }
 
 
+#if 0
+void Correction::write(odocstream & os) const
+{
+       os << "from: '" << from1_ << "' and '" << from2_
+          << "' to '" << to_ << '\'' << endl;
+}
+
+
 idocstream & operator>>(idocstream & is, Correction & corr)
 {
        corr.read(is);
@@ -106,7 +110,7 @@ odocstream & operator<<(odocstream & os, Correction & corr)
        corr.write(os);
        return os;
 }
-
+#endif
 
 
 
@@ -149,7 +153,7 @@ void initAutoCorrect()
        string line;
        ifstream is(file.toFilesystemEncoding().c_str());
        while (getline(is, line)) {
-               if (line.size() == 0 || line[0] == '#') {
+               if (line.empty() || line[0] == '#') {
                        //LYXERR(Debug::MATHED, "ignoring line '" << line << '\'');
                        continue;
                }