eliot-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Eliot-dev] eliot dic/automaton.cpp dic/header.cpp dic/rege...


From: eliot-dev
Subject: [Eliot-dev] eliot dic/automaton.cpp dic/header.cpp dic/rege...
Date: Sun, 20 Jul 2008 12:15:53 +0000

CVSROOT:        /sources/eliot
Module name:    eliot
Changes by:     Olivier Teulière <ipkiss>      08/07/20 12:15:53

Modified files:
        dic            : automaton.cpp header.cpp regexpmain.cpp 
        game           : bag.cpp game_io.cpp 
        utils          : ncurses.cpp 

Log message:
        Compilation fixes for some systems (missing headers)

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/eliot/dic/automaton.cpp?cvsroot=eliot&r1=1.3&r2=1.4
http://cvs.savannah.gnu.org/viewcvs/eliot/dic/header.cpp?cvsroot=eliot&r1=1.2&r2=1.3
http://cvs.savannah.gnu.org/viewcvs/eliot/dic/regexpmain.cpp?cvsroot=eliot&r1=1.5&r2=1.6
http://cvs.savannah.gnu.org/viewcvs/eliot/game/bag.cpp?cvsroot=eliot&r1=1.9&r2=1.10
http://cvs.savannah.gnu.org/viewcvs/eliot/game/game_io.cpp?cvsroot=eliot&r1=1.8&r2=1.9
http://cvs.savannah.gnu.org/viewcvs/eliot/utils/ncurses.cpp?cvsroot=eliot&r1=1.25&r2=1.26

Patches:
Index: dic/automaton.cpp
===================================================================
RCS file: /sources/eliot/eliot/dic/automaton.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- dic/automaton.cpp   13 Jul 2008 07:55:47 -0000      1.3
+++ dic/automaton.cpp   20 Jul 2008 12:15:51 -0000      1.4
@@ -29,6 +29,7 @@
 
 #include <set>
 #include <list>
+#include <algorithm>
 #include <cassert>
 #include <cstring>
 #include <cstdlib>
@@ -457,7 +458,7 @@
         astate ns = *it;
         int idx = *(ns->id.begin());
         DMSG(printf("%s ", s_state_id_to_str(ns->id).c_str()));
-        if (ns->accept && (find(s->id.begin(), s->id.end(), idx) != 
s->id.end()))
+        if (ns->accept && (std::find(s->id.begin(), s->id.end(), idx) != 
s->id.end()))
         {
             DMSG(printf("(ok) "));
             s->accept = true;

Index: dic/header.cpp
===================================================================
RCS file: /sources/eliot/eliot/dic/header.cpp,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -b -r1.2 -r1.3
--- dic/header.cpp      8 Jan 2008 13:52:35 -0000       1.2
+++ dic/header.cpp      20 Jul 2008 12:15:52 -0000      1.3
@@ -20,6 +20,7 @@
 
 #include "config.h"
 
+#include <cstring> // for strcpy
 #include <string>
 #include <sstream>
 #include <iostream>

Index: dic/regexpmain.cpp
===================================================================
RCS file: /sources/eliot/eliot/dic/regexpmain.cpp,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -b -r1.5 -r1.6
--- dic/regexpmain.cpp  13 Jul 2008 07:55:47 -0000      1.5
+++ dic/regexpmain.cpp  20 Jul 2008 12:15:52 -0000      1.6
@@ -29,6 +29,7 @@
 
 #include <exception>
 #include <iostream>
+#include <cstring> // For memset
 
 #if ENABLE_NLS
 #   include <libintl.h>

Index: game/bag.cpp
===================================================================
RCS file: /sources/eliot/eliot/game/bag.cpp,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- game/bag.cpp        8 Jan 2008 13:52:37 -0000       1.9
+++ game/bag.cpp        20 Jul 2008 12:15:52 -0000      1.10
@@ -20,6 +20,7 @@
  *****************************************************************************/
 
 #include <string>
+#include <cstdlib> // For rand()
 
 #include <dic.h>
 #include "bag.h"

Index: game/game_io.cpp
===================================================================
RCS file: /sources/eliot/eliot/game/game_io.cpp,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -b -r1.8 -r1.9
--- game/game_io.cpp    28 Jan 2008 19:17:35 -0000      1.8
+++ game/game_io.cpp    20 Jul 2008 12:15:52 -0000      1.9
@@ -1,6 +1,6 @@
 /*****************************************************************************
  * Eliot
- * Copyright (C) 2002-2007 Antoine Fraboulet & Olivier Teulière
+ * Copyright (C) 2002-2008 Antoine Fraboulet & Olivier Teulière
  * Authors: Antoine Fraboulet <antoine.fraboulet @@ free.fr>
  *          Olivier Teulière <ipkiss @@ gmail.com>
  *
@@ -19,12 +19,8 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
  *****************************************************************************/
 
-/**
- *  \file   game_io.cpp
- *  \brief  Eliot game class file load/save handling
- *  \author Antoine Fraboulet & Olivier Teuliere
- *  \date   2002 - 2005
- */
+#include <cstring>
+#include <cstdlib> // For atoi
 
 #include "dic.h"
 #include "pldrack.h"

Index: utils/ncurses.cpp
===================================================================
RCS file: /sources/eliot/eliot/utils/ncurses.cpp,v
retrieving revision 1.25
retrieving revision 1.26
diff -u -b -r1.25 -r1.26
--- utils/ncurses.cpp   19 Jan 2008 19:33:08 -0000      1.25
+++ utils/ncurses.cpp   20 Jul 2008 12:15:53 -0000      1.26
@@ -1,5 +1,5 @@
 /*****************************************************************************
- * Copyright (C) 2005 Eliot
+ * Copyright (C) 2005-2008 Eliot
  * Authors: Olivier Teuliere  <address@hidden>
  *
  * This program is free software; you can redistribute it and/or modify
@@ -26,6 +26,7 @@
 #endif
 
 #include <ctype.h>
+#include <cstring> // For strlen
 #include <fstream>
 #include <algorithm>
 
@@ -268,7 +269,7 @@
 void CursesIntf::drawScoresRacks(WINDOW *win, int y, int x) const
 {
     // Compute the longest player name
-    unsigned int longest = 0;
+    size_t longest = 0;
     for (unsigned int i = 0; i < m_game->getNPlayers(); i++)
     {
         longest = std::max(longest, m_game->getPlayer(i).getName().size());




reply via email to

[Prev in Thread] Current Thread [Next in Thread]