forked from amazingfate/loongoffice
Change-Id: I4e9a7ebf323848a03e02da3e9ed39377d1df6715 Reviewed-on: https://gerrit.libreoffice.org/30771 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Andras Timar <andras.timar@collabora.com>
61 lines
3.0 KiB
Groff
61 lines
3.0 KiB
Groff
diff -urN graphite2-1.3.4.orig/src/inc/json.h graphite2-1.3.4/src/inc/json.h
|
|
--- graphite2-1.3.4.orig/src/inc/json.h 2015-12-22 14:25:46.403566441 +0100
|
|
+++ graphite2-1.3.4/src/inc/json.h 2015-12-22 14:26:13.439722846 +0100
|
|
@@ -85,6 +85,9 @@
|
|
json & operator << (string) throw();
|
|
json & operator << (number) throw();
|
|
json & operator << (integer) throw();
|
|
+#ifdef _WIN64
|
|
+ json & operator << (size_t) throw();
|
|
+#endif
|
|
json & operator << (long unsigned int d) throw();
|
|
json & operator << (boolean) throw();
|
|
json & operator << (_null_t) throw();
|
|
diff -urN graphite2-1.3.4.orig/src/inc/Main.h graphite2-1.3.4/src/inc/Main.h
|
|
--- graphite2-1.3.4.orig/src/inc/Main.h 2015-12-22 14:25:46.399566417 +0100
|
|
+++ graphite2-1.3.4/src/inc/Main.h 2015-12-22 14:26:13.439722846 +0100
|
|
@@ -25,6 +25,9 @@
|
|
of the License or (at your option) any later version.
|
|
*/
|
|
#pragma once
|
|
+#ifdef _WIN32
|
|
+#pragma warning(disable: 4510 4610)
|
|
+#endif
|
|
|
|
#include <cstdlib>
|
|
#include "graphite2/Types.h"
|
|
diff -urN graphite2-1.3.4.orig/src/json.cpp graphite2-1.3.4/src/json.cpp
|
|
--- graphite2-1.3.4.orig/src/json.cpp 2015-12-22 14:25:46.399566417 +0100
|
|
+++ graphite2-1.3.4/src/json.cpp 2015-12-22 14:26:13.439722846 +0100
|
|
@@ -133,6 +133,9 @@
|
|
}
|
|
json & json::operator << (json::integer d) throw() { context(seq); fprintf(_stream, "%ld", d); return *this; }
|
|
json & json::operator << (long unsigned d) throw() { context(seq); fprintf(_stream, "%ld", d); return *this; }
|
|
+#ifdef _WIN64
|
|
+json & json::operator << (size_t d) throw() { context(seq); fprintf(_stream, "%ld", d); return *this; }
|
|
+#endif
|
|
json & json::operator << (json::boolean b) throw() { context(seq); fputs(b ? "true" : "false", _stream); return *this; }
|
|
json & json::operator << (json::_null_t) throw() { context(seq); fputs("null",_stream); return *this; }
|
|
|
|
diff -urN graphite2-1.3.4.orig/src/Pass.cpp graphite2-1.3.4/src/Pass.cpp
|
|
--- graphite2-1.3.4.orig/src/Pass.cpp 2015-12-22 14:25:46.399566417 +0100
|
|
+++ graphite2-1.3.4/src/Pass.cpp 2015-12-22 14:26:13.439722846 +0100
|
|
@@ -568,7 +568,7 @@
|
|
if (r->rule->preContext > fsm.slots.context())
|
|
continue;
|
|
*fsm.dbgout << json::flat << json::object
|
|
- << "id" << r->rule - m_rules
|
|
+ << "id" << static_cast<size_t>(r->rule - m_rules)
|
|
<< "failed" << true
|
|
<< "input" << json::flat << json::object
|
|
<< "start" << objectid(dslot(&fsm.slots.segment, input_slot(fsm.slots, -r->rule->preContext)))
|
|
@@ -582,7 +582,7 @@
|
|
void Pass::dumpRuleEventOutput(const FiniteStateMachine & fsm, const Rule & r, Slot * const last_slot) const
|
|
{
|
|
*fsm.dbgout << json::item << json::flat << json::object
|
|
- << "id" << &r - m_rules
|
|
+ << "id" << static_cast<size_t>(&r - m_rules)
|
|
<< "failed" << false
|
|
<< "input" << json::flat << json::object
|
|
<< "start" << objectid(dslot(&fsm.slots.segment, input_slot(fsm.slots, 0)))
|