From 4cc605a701779aff9c415a5521df0cc28e4b670a Mon Sep 17 00:00:00 2001 From: Edouard Dupin Date: Tue, 19 Jun 2012 16:53:17 +0200 Subject: [PATCH] Correction of the compilation inside android --- Sources/liblua/lua/llex.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Sources/liblua/lua/llex.cpp b/Sources/liblua/lua/llex.cpp index 74deebb9..fcdb1ac8 100644 --- a/Sources/liblua/lua/llex.cpp +++ b/Sources/liblua/lua/llex.cpp @@ -210,6 +210,7 @@ static void buffreplace (LexState *ls, char from, char to) { ** the one defined in the current locale and check again */ static void trydecpoint (LexState *ls, SemInfo *seminfo) { +#ifndef __PLATFORM__Android char old = ls->decpoint; ls->decpoint = getlocaledecpoint(); buffreplace(ls, old, ls->decpoint); /* try new decimal separator */ @@ -218,6 +219,11 @@ static void trydecpoint (LexState *ls, SemInfo *seminfo) { buffreplace(ls, ls->decpoint, '.'); /* undo change (for error message) */ lexerror(ls, "malformed number", TK_NUMBER); } +#else + /* format error with correct decimal point: no more options */ + buffreplace(ls, ls->decpoint, '.'); /* undo change (for error message) */ + lexerror(ls, "malformed number", TK_NUMBER); +#endif }