FYI. Just no-brainer stuff to make it compile.
--
Angus
Index: src/ChangeLog
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/ChangeLog,v
retrieving revision 1.1840
diff -u -p -r1.1840 ChangeLog
--- src/ChangeLog 23 Mar 2004 14:39:40 -0000 1.1840
+++ src/ChangeLog 24 Mar 2004 17:03:13 -0000
@@ -1,3 +1,17 @@
+2004-03-24 Angus Leeming <[EMAIL PROTECTED]>
+
+ 64-bit compile fixes.
+
+ * errorlist.[Ch] (pos_start, pos_end): store as lyx::pos_type.
+ (c-tor): pass lyx::pos_types rather than ints.
+
+ * paragraph.[Ch] (beginOfBody, begin_of_body_): return, store as
+ lyx::pos_type.
+
+ * text.C (Delete): compile fix.
+ (getPar): ensure that function declaration is the same as that in
+ the header file.
+
2004-03-23 Angus Leeming <[EMAIL PROTECTED]>
* ispell.C (LaunchIspell):
Index: src/errorlist.C
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/errorlist.C,v
retrieving revision 1.5
diff -u -p -r1.5 errorlist.C
--- src/errorlist.C 6 Oct 2003 15:42:15 -0000 1.5
+++ src/errorlist.C 24 Mar 2004 17:03:13 -0000
@@ -12,13 +12,14 @@
#include "errorlist.h"
+using lyx::pos_type;
using std::string;
-ErrorItem::ErrorItem(string const & error, string const & description,
- int par_id, int pos_start, int pos_end)
- : error(error), description(description), par_id(par_id),
- pos_start(pos_start), pos_end(pos_end)
+ErrorItem::ErrorItem(string const & error_, string const & description_,
+ int par_id_, pos_type pos_start_, pos_type pos_end_)
+ : error(error_), description(description_), par_id(par_id_),
+ pos_start(pos_start_), pos_end(pos_end_)
{}
Index: src/errorlist.h
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/errorlist.h,v
retrieving revision 1.8
diff -u -p -r1.8 errorlist.h
--- src/errorlist.h 6 Oct 2003 15:42:15 -0000 1.8
+++ src/errorlist.h 24 Mar 2004 17:03:13 -0000
@@ -12,6 +12,8 @@
#ifndef ERRORLIST_H
#define ERRORLIST_H
+#include "support/types.h"
+
#include <vector>
#include <string>
@@ -22,10 +24,10 @@ struct ErrorItem {
std::string error;
std::string description;
int par_id;
- int pos_start;
- int pos_end;
+ lyx::pos_type pos_start;
+ lyx::pos_type pos_end;
ErrorItem(std::string const & error, std::string const & description,
- int parid, int posstart, int posend);
+ int parid, lyx::pos_type posstart, lyx::pos_type posend);
ErrorItem();
};
Index: src/paragraph.C
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/paragraph.C,v
retrieving revision 1.357
diff -u -p -r1.357 paragraph.C
--- src/paragraph.C 19 Mar 2004 16:36:52 -0000 1.357
+++ src/paragraph.C 24 Mar 2004 17:03:13 -0000
@@ -645,7 +645,7 @@ void Paragraph::applyLayout(LyXLayout_pt
}
-int Paragraph::beginOfBody() const
+pos_type Paragraph::beginOfBody() const
{
return begin_of_body_;
}
Index: src/paragraph.h
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/paragraph.h,v
retrieving revision 1.127
diff -u -p -r1.127 paragraph.h
--- src/paragraph.h 19 Mar 2004 16:36:52 -0000 1.127
+++ src/paragraph.h 24 Mar 2004 17:03:13 -0000
@@ -202,7 +202,7 @@ public:
/// the paragraph alongside the text of the rest of the paragraph
/// (the body). This function returns the starting position of the
/// body of the text in the paragraph.
- int beginOfBody() const;
+ lyx::pos_type beginOfBody() const;
/// recompute this value
void setBeginOfBody();
@@ -353,7 +353,7 @@ private:
// for average tasks as buffer loading/switching etc.
TextContainer text_;
/// end of label
- int begin_of_body_;
+ lyx::pos_type begin_of_body_;
struct Pimpl;
///
Index: src/text.C
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/text.C,v
retrieving revision 1.553
diff -u -p -r1.553 text.C
--- src/text.C 18 Mar 2004 13:28:46 -0000 1.553
+++ src/text.C 24 Mar 2004 17:03:14 -0000
@@ -1341,7 +1341,8 @@ void LyXText::Delete(LCursor & cur)
CursorSlice sl = cur.top();
cursorRight(cur);
if (sl == cur.top()) {
- recordUndo(cur, Undo::DELETE, cur.par(), max(0, cur.par() - 1));
+ recordUndo(cur, Undo::DELETE, cur.par(),
+ max(par_type(0), cur.par() - 1));
backspace(cur);
}
}
@@ -1442,7 +1443,7 @@ ParagraphList::iterator LyXText::getPar(
}
-ParagraphList::iterator LyXText::getPar(int par) const
+ParagraphList::iterator LyXText::getPar(par_type par) const
{
//lyxerr << "getPar: " << par << " from " << paragraphs().size() << endl;
BOOST_ASSERT(par >= 0);
Index: src/frontends/controllers/ChangeLog
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/frontends/controllers/ChangeLog,v
retrieving revision 1.417
diff -u -p -r1.417 ChangeLog
--- src/frontends/controllers/ChangeLog 17 Mar 2004 21:21:45 -0000 1.417
+++ src/frontends/controllers/ChangeLog 24 Mar 2004 17:03:14 -0000
@@ -1,3 +1,13 @@
+2004-03-24 Angus Leeming <[EMAIL PROTECTED]>
+
+ 64-bit compile fixes.
+
+ * ControlErrorList.C (goTo): use lyx::pos_type as type of
+ temporary vars.
+
+ * ControlSpellchecker.C (nextWord): pass progress as a
+ PosIterator::difference_type, not an int.
+
2004-03-17 Angus Leeming <[EMAIL PROTECTED]>
* ControlForks.[Ch]: removed.
Index: src/frontends/controllers/ControlErrorList.C
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/frontends/controllers/ControlErrorList.C,v
retrieving revision 1.18
diff -u -p -r1.18 ControlErrorList.C
--- src/frontends/controllers/ControlErrorList.C 27 Jan 2004 15:14:34 -0000 1.18
+++ src/frontends/controllers/ControlErrorList.C 24 Mar 2004 17:03:14 -0000
@@ -68,9 +68,9 @@ void ControlErrorList::goTo(int item)
return;
}
- int const end = std::min(err.pos_end, pit->size());
- int const start = std::min(err.pos_start, end);
- int const range = end - start;
+ lyx::pos_type const end = std::min(err.pos_end, pit->size());
+ lyx::pos_type const start = std::min(err.pos_start, end);
+ lyx::pos_type const range = end - start;
// Now make the selection.
PosIterator const pos(pit, start);
Index: src/frontends/controllers/ControlSpellchecker.C
===================================================================
RCS file: /usr/local/lyx/cvsroot/lyx-devel/src/frontends/controllers/ControlSpellchecker.C,v
retrieving revision 1.64
diff -u -p -r1.64 ControlSpellchecker.C
--- src/frontends/controllers/ControlSpellchecker.C 13 Feb 2004 07:30:58 -0000 1.64
+++ src/frontends/controllers/ControlSpellchecker.C 24 Mar 2004 17:03:14 -0000
@@ -160,7 +160,8 @@ bool isLetter(PosIterator & cur)
WordLangTuple nextWord(PosIterator & cur, PosIterator const & end,
- int & progress, BufferParams & bp)
+ PosIterator::difference_type & progress,
+ BufferParams & bp)
{
// skip until we have real text (will jump paragraphs)
for (; cur != end && !isLetter(cur); ++cur, ++progress);