1 // { dg-lto-do link }
2 // { dg-require-effective-target shared }
3 // { dg-require-effective-target fpic }
4 // { dg-lto-options {{-O0 -fPIC -shared -flto}} }
5
6 template < typename _Tp, _Tp __v > struct integral_constant {
7 static constexpr _Tp value = __v;
8 };
9 typedef integral_constant< bool, false > false_type;
10 struct __is_void_helper : false_type {};
11 struct is_void : __is_void_helper {};
12 template < typename > struct is_array : false_type {};
13 namespace __gnu_cxx {
14 enum _Lock_policy { _S_single, _S_mutex, _S_atomic }; // { dg-lto-warning "6: type '_Lock_policy' violates the C\\+\\+ One Definition Rule" }
15 const _Lock_policy __default_lock_policy = _S_atomic;
16 } namespace std {
17 using __gnu_cxx::_Lock_policy;
18 using __gnu_cxx::__default_lock_policy;
19 template < _Lock_policy = __default_lock_policy > class _Sp_counted_base;
20 template < typename, _Lock_policy = __default_lock_policy > class __shared_ptr;
21 template < _Lock_policy > class __shared_count { _Sp_counted_base<> *_M_pi; };
22 template < typename _Tp, _Lock_policy, bool = is_array< _Tp >::value,
23 bool = is_void::value >
24 class __shared_ptr_access {};
25 template < typename _Tp, _Lock_policy _Lp >
26 class __shared_ptr : __shared_ptr_access< _Tp, _Lp > {
27 using element_type = _Tp;
28 element_type *_M_ptr;
29 __shared_count< _Lp > _M_refcount;
30 };
31 template < typename _Tp > class shared_ptr : __shared_ptr< _Tp > {};
32 } typedef struct _rtl_String rtl_String;
33 typedef struct _rtl_uString rtl_uString;
34 namespace rtl {
35 class OString {
36 rtl_String *pData;
37 };
38 } using rtl::OString;
39 namespace rtl {
40 class OUString {
41 rtl_uString *pData;
42 };
43 } using rtl::OUString;
44 namespace tools {
45 template < typename T > class SvRef {
46 T *pObj;
47 };
48 } class SvRefBase {
49 unsigned nRefCount : 31;
50 unsigned bNoDelete : 1;
51
52 protected:
53 virtual ~SvRefBase();
54 };
55 class ErrCode {
56 unsigned m_value;
57 };
58 class SvStream;
59 class SfxMedium;
60 struct strong_int {
61 unsigned short m_value;
62 };
63 typedef strong_int LanguageType;
64 class SotObject : virtual SvRefBase {
65 unsigned short nOwnerLockCount;
66 bool bInClose;
67 };
68 class BaseStorage;
69 class SotStorage : virtual SotObject {
70 BaseStorage *m_pOwnStg;
71 SvStream *m_pStorStm;
72 ErrCode m_nError;
73 OUString m_aName;
74 bool m_bIsRoot;
75 bool m_bDelStm;
76 OString m_aKey;
77 int m_nVersion;
78 };
79 class ScDocument;
80 class ScAddress {
81 int nRow;
82 short nCol;
83 short nTab;
84 };
85 enum XclBiff {};
86 enum XclOutput {};
87 enum BiffTyp {};
88 class SharedFormulaBuffer;
89 class ExtNameBuff;
90 class ExtSheetBuffer;
91 class ExcelToSc;
92 class XclImpColRowSettings;
93 struct RootData {
94 BiffTyp eDateiTyp;
95 ExtSheetBuffer *pExtSheetBuff;
96 SharedFormulaBuffer *pShrfmlaBuff;
97 ExtNameBuff *pExtNameBuff;
98 ExcelToSc *pFmlaConverter;
99 XclImpColRowSettings *pColRowBuff;
100 };
101 class ScEditEngineDefaulter;
102 class ScHeaderEditEngine;
103 class EditEngine;
104 class ScExtDocOptions;
105 class XclFontPropSetHelper;
106 class XclChPropSetHelper;
107 class XclTracer;
108 struct XclRootData {
109 typedef std::shared_ptr< ScEditEngineDefaulter > ScEEDefaulterRef;
110 typedef std::shared_ptr< ScHeaderEditEngine > ScHeaderEERef;
111 typedef std::shared_ptr< EditEngine > EditEngineRef;
112 typedef std::shared_ptr< XclFontPropSetHelper > XclFontPropSetHlpRef;
113 typedef std::shared_ptr< XclChPropSetHelper > XclChPropSetHlpRef;
114 typedef std::shared_ptr< ScExtDocOptions > ScExtDocOptRef;
115 typedef std::shared_ptr< XclTracer > XclTracerRef;
116 typedef std::shared_ptr< RootData > RootDataRef;
117 XclBiff meBiff;
118 XclOutput meOutput;
119 SfxMedium &mrMedium;
120 tools::SvRef< SotStorage > mxRootStrg;
121 ScDocument &mrDoc;
122 OUString maDocUrl;
123 OUString maBasePath;
124 OUString maUserName;
125 OUString maDefPassword;
126 unsigned short meTextEnc;
127 LanguageType meSysLang;
128 LanguageType meDocLang;
129 LanguageType meUILang;
130 short mnDefApiScript;
131 ScAddress maScMaxPos;
132 ScAddress maXclMaxPos;
133 ScAddress maMaxPos;
134 ScEEDefaulterRef mxEditEngine;
135 ScHeaderEERef mxHFEditEngine;
136 EditEngineRef mxDrawEditEng;
137 XclFontPropSetHlpRef mxFontPropSetHlp;
138 XclChPropSetHlpRef mxChPropSetHlp;
139 ScExtDocOptRef mxExtDocOpt;
140 XclTracerRef mxTracer;
141 RootDataRef mxRD;
142 virtual ~XclRootData();
143 };
144 class XclRoot {
145 public:
146 virtual ~XclRoot();
147 XclRootData &mrData;
148 };
149 class XclImpRoot : XclRoot {};
150 class XclImpColRowSettings : XclImpRoot {};
lcl_ExportExcelBiff()151 void lcl_ExportExcelBiff() {
152 XclRootData aExpData();
153 }
154