summaryrefslogtreecommitdiff
path: root/bridges
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2014-04-08 10:35:57 +0200
committerStephan Bergmann <sbergman@redhat.com>2014-04-08 10:35:57 +0200
commitf598a018f153d005887bc994f93719e2da37c9cf (patch)
tree6dd80ca5b74f3b271a101ceb44e7c2dde129bd21 /bridges
parent532e8ccd8b5fe7c2b7eee4ff167ac6c53b9ba87d (diff)
Clean up function declarations
Change-Id: I5d3ed0a266f327dbc8d506090221c43ef89fbcc0
Diffstat (limited to 'bridges')
-rw-r--r--bridges/source/cpp_uno/gcc3_linux_x86-64/call.hxx34
-rw-r--r--bridges/source/cpp_uno/gcc3_linux_x86-64/cpp2uno.cxx3
-rw-r--r--bridges/source/cpp_uno/shared/cppinterfaceproxy.cxx4
-rw-r--r--bridges/source/cpp_uno/shared/vtablefactory.cxx8
4 files changed, 42 insertions, 7 deletions
diff --git a/bridges/source/cpp_uno/gcc3_linux_x86-64/call.hxx b/bridges/source/cpp_uno/gcc3_linux_x86-64/call.hxx
new file mode 100644
index 000000000000..3e5d3166bc47
--- /dev/null
+++ b/bridges/source/cpp_uno/gcc3_linux_x86-64/call.hxx
@@ -0,0 +1,34 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * This file is part of the LibreOffice project.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ *
+ * This file incorporates work covered by the following license notice:
+ *
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed
+ * with this work for additional information regarding copyright
+ * ownership. The ASF licenses this file to you under the Apache
+ * License, Version 2.0 (the "License"); you may not use this file
+ * except in compliance with the License. You may obtain a copy of
+ * the License at http://www.apache.org/licenses/LICENSE-2.0 .
+ */
+
+#ifndef INCLUDED_BRIDGES_SOURCE_CPP_UNO_GCC3_LINUX_X86_64_CALL_HXX
+#define INCLUDED_BRIDGES_SOURCE_CPP_UNO_GCC3_LINUX_X86_64_CALL_HXX
+
+#include <sal/config.h>
+
+#include <sal/types.h>
+
+extern "C" typelib_TypeClass cpp_vtable_call(
+ sal_Int32 nFunctionIndex, sal_Int32 nVtableOffset,
+ void ** gpreg, void ** fpreg, void ** ovrflw,
+ sal_uInt64 * pRegisterReturn /* space for register return */ );
+
+#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/bridges/source/cpp_uno/gcc3_linux_x86-64/cpp2uno.cxx b/bridges/source/cpp_uno/gcc3_linux_x86-64/cpp2uno.cxx
index 175697764892..2373769745d8 100644
--- a/bridges/source/cpp_uno/gcc3_linux_x86-64/cpp2uno.cxx
+++ b/bridges/source/cpp_uno/gcc3_linux_x86-64/cpp2uno.cxx
@@ -36,6 +36,7 @@
#include "bridges/cpp_uno/shared/vtablefactory.hxx"
#include "abi.hxx"
+#include "call.hxx"
#include "share.hxx"
using namespace ::osl;
@@ -252,7 +253,7 @@ static typelib_TypeClass cpp2uno_call(
}
-extern "C" typelib_TypeClass cpp_vtable_call(
+typelib_TypeClass cpp_vtable_call(
sal_Int32 nFunctionIndex, sal_Int32 nVtableOffset,
void ** gpreg, void ** fpreg, void ** ovrflw,
sal_uInt64 * pRegisterReturn /* space for register return */ )
diff --git a/bridges/source/cpp_uno/shared/cppinterfaceproxy.cxx b/bridges/source/cpp_uno/shared/cppinterfaceproxy.cxx
index e511627d5d54..4488e7417964 100644
--- a/bridges/source/cpp_uno/shared/cppinterfaceproxy.cxx
+++ b/bridges/source/cpp_uno/shared/cppinterfaceproxy.cxx
@@ -39,8 +39,8 @@
static bridges::cpp_uno::shared::VtableFactory * pInstance;
#if defined(__GNUG__) && !defined(__MINGW32__)
-void dso_init(void) __attribute__((constructor));
-void dso_exit(void) __attribute__((destructor));
+extern "C" void dso_init(void) __attribute__((constructor));
+extern "C" void dso_exit(void) __attribute__((destructor));
#endif
void dso_init(void) {
diff --git a/bridges/source/cpp_uno/shared/vtablefactory.cxx b/bridges/source/cpp_uno/shared/vtablefactory.cxx
index 43a5c81e555c..f6e9e7c2e961 100644
--- a/bridges/source/cpp_uno/shared/vtablefactory.cxx
+++ b/bridges/source/cpp_uno/shared/vtablefactory.cxx
@@ -35,6 +35,7 @@
#include "sal/types.h"
#include "typelib/typedescription.hxx"
+#include <boost/noncopyable.hpp>
#include <boost/unordered_map.hpp>
#include <new>
#include <vector>
@@ -120,7 +121,9 @@ extern "C" void SAL_CALL freeExec(
}
-class VtableFactory::GuardedBlocks: public std::vector< Block > {
+class VtableFactory::GuardedBlocks:
+ public std::vector<Block>, private boost::noncopyable
+{
public:
GuardedBlocks(VtableFactory const & factory):
m_factory(factory), m_guarded(true) {}
@@ -130,9 +133,6 @@ public:
void unguard() { m_guarded = false; }
private:
- GuardedBlocks(GuardedBlocks &); // not implemented
- void operator =(GuardedBlocks); // not implemented
-
VtableFactory const & m_factory;
bool m_guarded;
};