summaryrefslogtreecommitdiffstats
path: root/basic/source/runtime/methods1.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'basic/source/runtime/methods1.cxx')
-rw-r--r--basic/source/runtime/methods1.cxx15
1 files changed, 15 insertions, 0 deletions
diff --git a/basic/source/runtime/methods1.cxx b/basic/source/runtime/methods1.cxx
index 2f9b6ff7b655..3d0c378765c8 100644
--- a/basic/source/runtime/methods1.cxx
+++ b/basic/source/runtime/methods1.cxx
@@ -2968,6 +2968,21 @@ void SbRtl_CompatibilityMode(StarBASIC *, SbxArray & rPar, bool)
rPar.Get32(0)->PutBool( bEnabled );
}
+bool LibreOffice6FloatingPointMode()
+{
+ static bool bMode = std::getenv("LIBREOFFICE6FLOATINGPOINTMODE") != nullptr;
+
+ return bMode;
+}
+
+void SbRtl_LibreOffice6FloatingPointMode(StarBASIC *, SbxArray & rPar, bool)
+{
+ if ( rPar.Count32() != 1 )
+ StarBASIC::Error( ERRCODE_BASIC_BAD_ARGUMENT );
+
+ rPar.Get32(0)->PutBool( LibreOffice6FloatingPointMode() );
+}
+
void SbRtl_Input(StarBASIC *, SbxArray & rPar, bool)
{
// 2 parameters needed