diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2017-03-05 13:19:41 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2017-03-05 15:10:37 +0000 |
commit | 177f5c2e505b7978fc232a891577a448e49b290d (patch) | |
tree | 8fcb4ca27cfdb49ee44d884809c60455b5ecfa03 /svl/source/items/aeitem.cxx | |
parent | d8a47a23114ce9b4a743d0da35dfb93dadc07d11 (diff) |
Proper fix for multiply defined SfxEnumItem<sal_uInt16> with MSVC
With --disable-pch the original hack from
f091259ad2ec1590714645839668580cd7b8c7c4 "convert SfxEnumItem to type-safe
template class" doesn't happen to work: When linking sd, the occurrences of
SfxEnumItem<sal_uInt16> in sd/inc/sdattr.hxx clash with those from editeng
(where LanguageType is a typedef for sal_uInt16) and svl (as the respective
include files from editeng and svl happen to not be included). For whatever
reason, the explicit instantiation declaration without a __declspec(...) in
include/svl/eitem.hxx doesn't seem to make a difference (at least with MSVC 2015
Update 3).
Change-Id: I51b5943fe19a7184db9414192c6364f7c26b79eb
Reviewed-on: https://gerrit.libreoffice.org/34903
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Tested-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'svl/source/items/aeitem.cxx')
-rw-r--r-- | svl/source/items/aeitem.cxx | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/svl/source/items/aeitem.cxx b/svl/source/items/aeitem.cxx index 00c6149a55eb..b10b36d0524b 100644 --- a/svl/source/items/aeitem.cxx +++ b/svl/source/items/aeitem.cxx @@ -35,14 +35,14 @@ class SfxAllEnumValueArr : public std::vector<SfxAllEnumValue_Impl> {}; SfxAllEnumItem::SfxAllEnumItem() : - SfxEnumItem<sal_uInt16>(0, 0), + SfxAllEnumItem_Base(0, 0), pValues( nullptr ), pDisabledValues( nullptr ) { } SfxAllEnumItem::SfxAllEnumItem(sal_uInt16 which, sal_uInt16 nVal): - SfxEnumItem(which, nVal), + SfxAllEnumItem_Base(which, nVal), pValues( nullptr ), pDisabledValues( nullptr ) { @@ -50,7 +50,7 @@ SfxAllEnumItem::SfxAllEnumItem(sal_uInt16 which, sal_uInt16 nVal): } SfxAllEnumItem::SfxAllEnumItem( sal_uInt16 which, SvStream &rStream ): - SfxEnumItem(which, rStream), + SfxAllEnumItem_Base(which, rStream), pValues( nullptr ), pDisabledValues( nullptr ) { @@ -58,14 +58,14 @@ SfxAllEnumItem::SfxAllEnumItem( sal_uInt16 which, SvStream &rStream ): } SfxAllEnumItem::SfxAllEnumItem(sal_uInt16 which): - SfxEnumItem(which, 0), + SfxAllEnumItem_Base(which, 0), pValues( nullptr ), pDisabledValues( nullptr ) { } SfxAllEnumItem::SfxAllEnumItem(const SfxAllEnumItem &rCopy): - SfxEnumItem(rCopy), + SfxAllEnumItem_Base(rCopy), pValues(nullptr), pDisabledValues( nullptr ) { |