From 9d29d3dad4e944182b2fad6e58bd1cd02aa0a8fd Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Tue, 14 Feb 2017 20:32:18 +0200 Subject: BOOST_SPIRIT_SINGLE_GRAMMAR_INSTANCE has been defined forever in these files Change-Id: I0afa1b404192f44540aa318e748452e0328fac6b --- connectivity/source/commontools/RowFunctionParser.cxx | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'connectivity') diff --git a/connectivity/source/commontools/RowFunctionParser.cxx b/connectivity/source/commontools/RowFunctionParser.cxx index dd7d05f03900..cada6eeb03e2 100644 --- a/connectivity/source/commontools/RowFunctionParser.cxx +++ b/connectivity/source/commontools/RowFunctionParser.cxx @@ -23,6 +23,7 @@ // But watch out, the parser might have // state not visible to this code! #define BOOST_SPIRIT_SINGLE_GRAMMAR_INSTANCE + #if OSL_DEBUG_LEVEL >= 2 && defined(DBG_UTIL) #include #define BOOST_SPIRIT_DEBUG @@ -385,7 +386,6 @@ private: ParserContextSharedPtr mpParserContext; // might get modified during parsing }; -#ifdef BOOST_SPIRIT_SINGLE_GRAMMAR_INSTANCE const ParserContextSharedPtr& getParserContext() { static ParserContextSharedPtr lcl_parserContext( new ParserContext() ); @@ -397,7 +397,7 @@ const ParserContextSharedPtr& getParserContext() return lcl_parserContext; } -#endif + } std::shared_ptr FunctionParser::parseFunction( const OUString& _sFunction) @@ -413,13 +413,9 @@ std::shared_ptr FunctionParser::parseFunction( const OUString& _ ParserContextSharedPtr pContext; -#ifdef BOOST_SPIRIT_SINGLE_GRAMMAR_INSTANCE // static parser context, because the actual // Spirit parser is also a static object pContext = getParserContext(); -#else - pContext.reset( new ParserContext() ); -#endif ExpressionGrammar aExpressionGrammer( pContext ); -- cgit