Not nice:

vspace.C: In member function `const std::string VSpace::asLatexCommand(const
BufferParams&) const':
vspace.C:478: Warnung: control reaches end of non-void function
vspace.C: In member function `int VSpace::inPixels(const BufferView&) const':
vspace.C:514: Warnung: control reaches end of non-void function


See attached patch.

Michael



Index: vspace.C
===================================================================
RCS file: /cvs/lyx/lyx-devel/src/vspace.C,v
retrieving revision 1.78
diff -u -r1.78 vspace.C
--- vspace.C    2003/11/13 13:43:41     1.78
+++ vspace.C    2003/11/21 17:10:20
@@ -475,6 +475,10 @@
                return keep_ ? "\\vspace*{" + len_.asLatexString() + '}'
                        : "\\vspace{" + len_.asLatexString() + '}';
        }
+
+       // suppress compiler warning
+       BOOST_ASSERT(false);
+       return "";
 }
 
 
@@ -511,4 +515,8 @@
        case LENGTH:
                return len_.len().inPixels(bv.workWidth());
        }
+
+       // suppress compiler warning
+       BOOST_ASSERT(false);
+       return 0;
 }

Reply via email to