1 diff --git a/codemaker/source/cppumaker/cpputype.cxx b/codemaker/source/cppumaker/cpputype.cxx
2 index 69fa71a..5da6316 100644
3 --- codemaker/source/cppumaker/cpputype.cxx
4 +++ codemaker/source/cppumaker/cpputype.cxx
5 @@ -2389,7 +2389,7 @@ sal_Bool StructureType::dumpDeclaration(FileStream& o)
8 o << indent() << "inline " << m_name << "() SAL_THROW(());\n";
9 - sal_uInt16 members = m_reader.getFieldCount();
10 + const sal_uInt16 members = m_reader.getFieldCount();
11 if (members > 0 || getInheritedMemberCount() > 0) {
12 o << "\n" << indent() << "inline " << m_name << "(";
13 bool prev = dumpSuperMember(o, base, true);
14 @@ -2445,6 +2445,58 @@ sal_Bool StructureType::dumpDeclaration(FileStream& o)
18 + if (isPolymorphic() && (members > 0 || getInheritedMemberCount() > 0)) {
20 + dumpTemplateHead(o);
23 + o << "inline " << m_name;
24 + dumpTemplateParameters(o);
27 + o << "make_" << m_name << "(";
28 + bool prev = dumpSuperMember(o, base, true);
29 + for (sal_uInt16 i = 0; i < members; ++i) {
35 + rtl::OUStringToOString(
36 + m_reader.getFieldTypeName(i), RTL_TEXTENCODING_UTF8));
37 + if ((m_reader.getFieldFlags(i) & RT_ACCESS_PARAMETERIZED_TYPE) != 0)
39 + dumpTypeParameterName(o, type);
42 + dumpType(o, type, true, true);
45 + << rtl::OUStringToOString(
46 + m_reader.getFieldName(i), RTL_TEXTENCODING_UTF8);
48 + o << ") SAL_THROW(())\n";
49 + o << indent() << "{\n";
51 + o << indent() << "return " << m_name;
52 + dumpTemplateParameters(o);
55 + prev = dumpSuperMember(o, base, false);
56 + for (sal_uInt16 i = 0; i < members; ++i) {
61 + o << indent() << rtl::OUStringToOString(
62 + m_reader.getFieldName(i), RTL_TEXTENCODING_UTF8);
67 + o << indent() << "}\n\n";
70 o << "#ifdef SAL_W32\n"
71 << "# pragma pack(pop)\n"
72 << "#elif defined(SAL_OS2)\n"
73 diff --git a/codemaker/test/cppumaker/test_codemaker_cppumaker.cxx b/codemaker/test/cppumaker/test_codemaker_cppumaker.cxx
74 index 2d5e638..94f8569 100644
75 --- codemaker/test/cppumaker/test_codemaker_cppumaker.cxx
76 +++ codemaker/test/cppumaker/test_codemaker_cppumaker.cxx
77 @@ -444,10 +444,16 @@ void Test::testBigStruct() {
78 CPPUNIT_ASSERT_EQUAL(guard.p->m22.getLength(), static_cast< sal_Int32 >(0));
79 CPPUNIT_ASSERT_EQUAL(guard.p->m23.getLength(), static_cast< sal_Int32 >(0));
81 -#if defined __GNUC__ && __GNUC__ >= 3
82 +#if defined(__GNUC__) && __GNUC__ >= 3
83 +# if !defined(X86_64)
85 static_cast< std::size_t >(16),
86 sizeof (test::codemaker::cppumaker::AlignmentDerivedStruct));
88 + CPPUNIT_ASSERT_EQUAL(
89 + static_cast< std::size_t >(24),
90 + sizeof (test::codemaker::cppumaker::AlignmentDerivedStruct));
94 com::sun::star::uno::Type t(
95 diff --git a/codemaker/test/cppumaker/types.idl b/codemaker/test/cppumaker/types.idl
96 index 972f579..962aca8 100644
97 --- codemaker/test/cppumaker/types.idl
98 +++ codemaker/test/cppumaker/types.idl
101 ************************************************************************/
103 -//TODO: Do not depend on types for which C++ header files are only generated
104 -// later in the build process in offuh:
105 #include "com/sun/star/lang/ClassNotFoundException.idl"
106 #include "com/sun/star/lang/IllegalAccessException.idl"
107 #include "com/sun/star/lang/Locale.idl"