]> git.lyx.org Git - lyx.git/blobdiff - src/tests/check_layout.cpp
We only support gcc >= 4.9.
[lyx.git] / src / tests / check_layout.cpp
index 318ae4863f9837503ca236391156c52db43c76fa..afdb66777dfc3b3abef6a1f7ff3214ea2f53c0a8 100644 (file)
@@ -1,5 +1,6 @@
 #include <config.h>
 
+#include "../support/debug.h"
 #include "../support/FileName.h"
 #include "../support/filetools.h"
 #include "../Format.h"
 #include "../support/Package.h"
 
 #include <cstdlib>
+#include <fstream>
 #include <iostream>
+#include <sstream>
+using namespace std;
 
 
 namespace lyx {
 namespace frontend {
 namespace Alert {
-void warning(docstring const & title, docstring const & message, bool const &)
+void warning(docstring const & title, docstring const & message, bool)
 {
        LYXERR0(title);
        LYXERR0(message);
 }
-}
-}
+} // namespace Alert
+} // namespace frontend
 
 bool LaTeXFeatures::isAvailable(std::string const &)
 {
@@ -35,7 +39,7 @@ bool Formats::isZippedFile(support::FileName const &) const
 {
        return false;
 }
-}
+} // namespace lyx
 
 
 using namespace lyx::support;
@@ -54,7 +58,7 @@ bool test_Layout(string const & input, string const & output)
                return false;
        }
        LayoutFile const & f = l[i];
-       ostream * os = NULL;
+       ostream * os = nullptr;
        if (output == "-")
                os = &cout;
        else if (!output.empty())
@@ -115,7 +119,7 @@ bool test_Layout(string const & input, string const & output)
 
 int main(int argc, char * argv[])
 {
-       os::init(argc, argv);
+       os::init(argc, &argv);
        lyxerr.setStream(cerr);
        if (argc < 2 || argc > 3) {
                cerr << "Usage: " << argv[0] << " <input layout file> [<output layout file>]\n";