changeset 2415:d84bf9fcb368

Fix name of a test program (using a consistent suffix for C++ programs)
author Volker Grabsch <vog@notjusthosting.com>
date Mon, 16 Apr 2012 15:26:23 +0200
parents 639f0e5a9afa
children 7ddb24a19c22
files src/hunspell-test.cpp src/hunspell-test.cxx src/hunspell.mk
diffstat 3 files changed, 38 insertions(+), 38 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/hunspell-test.cpp	Mon Apr 16 15:26:23 2012 +0200
@@ -0,0 +1,37 @@
+/*
+ * This file is part of MXE.
+ * See index.html for further information.
+ */
+
+#include <iostream>
+#include <fstream>
+#include <hunspell.hxx>
+
+int main(int argc, char *argv[])
+{
+    (void)argc;
+    (void)argv;
+
+    std::ofstream dic ("hunspell-test.dic");
+    dic << "2\nHello\nWorld";
+    dic.close();
+    std::ofstream aff ("hunspell-test.aff");
+    aff << "SET UTF-8\nTRY loredWH\nMAXDIFF 1";
+    aff.close();
+    Hunspell h("hunspell-test.aff", "hunspell-test.dic");
+
+    if (h.spell("Hello") == 0)
+    {
+        std::cerr << "Error: hunspell marked correct word as wrong" << std::endl;
+    }
+    if (h.spell("wrld") != 0)
+    {
+        std::cerr << "Error: hunspell marked wrong word as correct" << std::endl;
+    }
+
+    char ** result;
+    int n = h.suggest(&result, "ell");
+    for (int i = 0; i < n; i++) std::cout << result[i];
+
+    return 0;
+}
--- a/src/hunspell-test.cxx	Mon Apr 16 15:25:27 2012 +0200
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,37 +0,0 @@
-/*
- * This file is part of MXE.
- * See index.html for further information.
- */
-
-#include <iostream>
-#include <fstream>
-#include <hunspell.hxx>
-
-int main(int argc, char *argv[])
-{
-    (void)argc;
-    (void)argv;
-
-    std::ofstream dic ("hunspell-test.dic");
-    dic << "2\nHello\nWorld";
-    dic.close();
-    std::ofstream aff ("hunspell-test.aff");
-    aff << "SET UTF-8\nTRY loredWH\nMAXDIFF 1";
-    aff.close();
-    Hunspell h("hunspell-test.aff", "hunspell-test.dic");
-
-    if (h.spell("Hello") == 0)
-    {
-        std::cerr << "Error: hunspell marked correct word as wrong" << std::endl;
-    }
-    if (h.spell("wrld") != 0)
-    {
-        std::cerr << "Error: hunspell marked wrong word as correct" << std::endl;
-    }
-
-    char ** result;
-    int n = h.suggest(&result, "ell");
-    for (int i = 0; i < n; i++) std::cout << result[i];
-
-    return 0;
-}
--- a/src/hunspell.mk	Mon Apr 16 15:25:27 2012 +0200
+++ b/src/hunspell.mk	Mon Apr 16 15:26:23 2012 +0200
@@ -31,6 +31,6 @@
     # Test
     '$(TARGET)-g++' \
         -W -Wall -Werror -ansi -pedantic \
-        '$(2).cxx' -o '$(PREFIX)/$(TARGET)/bin/test-hunspell.exe' \
+        '$(2).cpp' -o '$(PREFIX)/$(TARGET)/bin/test-hunspell.exe' \
         `'$(TARGET)-pkg-config' hunspell --cflags --libs`
 endef