Date: prev next · Thread: first prev next last
2012 Archives by date, by thread · List index


Be good to get this in, afaict this shouldn't cause any problems
see attached patch

Noel
From 778c2ad1225ee3d1e9ac40ab584d8f5f428845fe Mon Sep 17 00:00:00 2001
From: Noel Power <noel.power@novell.com>
Date: Thu, 12 Jan 2012 15:46:52 +0000
Subject: [PATCH] restore special DATE handling code for SbxValue::Compute fdo#44385

restore code that seemed to be erroneously moved as part of the currency enhancement feature
---
 basic/source/sbx/sbxvalue.cxx |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/basic/source/sbx/sbxvalue.cxx b/basic/source/sbx/sbxvalue.cxx
index e21234c..39dfadb 100644
--- a/basic/source/sbx/sbxvalue.cxx
+++ b/basic/source/sbx/sbxvalue.cxx
@@ -1311,9 +1311,6 @@ Lbl_OpIsDouble:
                             else aL.nDouble /= aR.nDouble; break;
                         case SbxPLUS:
                             aL.nDouble += aR.nDouble; break;
-                            // #45465 Date needs with "+" a special handling: forces date type
-                            if( GetType() == SbxDATE || rOp.GetType() == SbxDATE )
-                                aL.eType = SbxDATE;
                         case SbxMINUS:
                             aL.nDouble -= aR.nDouble; break;
                         case SbxNEG:
@@ -1321,6 +1318,9 @@ Lbl_OpIsDouble:
                         default:
                             SetError( SbxERR_NOTIMP );
                     }
+                    // #45465 Date needs with "+" a special handling: forces date type
+                    if( GetType() == SbxDATE || rOp.GetType() == SbxDATE )
+                        aL.eType = SbxDATE;
 
                 }
             }
-- 
1.7.3.4


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.