From kde-windows Wed Jun 20 14:35:52 2007 From: =?ISO-8859-2?Q?Jaros=B3aw_Staniek?= Date: Wed, 20 Jun 2007 14:35:52 +0000 To: kde-windows Subject: *_EXPORT not needed for static members Message-Id: <46793B48.20906 () iidea ! pl> X-MARC-Message: https://marc.info/?l=kde-windows&m=118235022531296 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--------------040102000503060907070107" This is a multi-part message in MIME format. --------------040102000503060907070107 Content-Type: text/plain; charset=ISO-8859-2; format=flowed Content-Transfer-Encoding: 7bit Hello, See the attached patch, fixing compialtion for msvc.net (2003). *_EXPORT is not needed for static members since class is exported itself. As the static members are public, to increase cross-dll safety (simply, their behaviour is not well defined across runtimes), wouldn't it be nice to add static functions instead of variables? Similar to KGlobal::locale(). -- regards / pozdrawiam, Jaroslaw Staniek Sponsored by OpenOffice Polska (http://www.openoffice.com.pl/en) to work on Kexi & KOffice: http://www.kexi.pl/en, http://www.koffice.org KDE3 & KDE4 Libraries for MS Windows: http://kdelibs.com, http://www.kde.org --------------040102000503060907070107 Content-Type: text/plain; name="static_export.patch" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="static_export.patch" Index: src/streamanalyzer/fieldtypes.cpp =================================================================== --- src/streamanalyzer/fieldtypes.cpp (revision 677989) +++ src/streamanalyzer/fieldtypes.cpp (working copy) @@ -27,22 +27,22 @@ : m_key(k), m_type(t), m_maxoccurs(m), m_parent(p), m_writerdata(0) { } -STREAMANALYZER_EXPORT const string FieldRegister::floatType = "float"; -STREAMANALYZER_EXPORT const string FieldRegister::integerType = "integer"; -STREAMANALYZER_EXPORT const string FieldRegister::binaryType = "binary"; -STREAMANALYZER_EXPORT const string FieldRegister::stringType = "string"; -STREAMANALYZER_EXPORT const string FieldRegister::datetimeType = "datetime"; +const string FieldRegister::floatType = "float"; +const string FieldRegister::integerType = "integer"; +const string FieldRegister::binaryType = "binary"; +const string FieldRegister::stringType = "string"; +const string FieldRegister::datetimeType = "datetime"; -STREAMANALYZER_EXPORT const string FieldRegister::pathFieldName = "system.location"; -STREAMANALYZER_EXPORT const string FieldRegister::encodingFieldName = "content.charset"; -STREAMANALYZER_EXPORT const string FieldRegister::mimetypeFieldName = "content.mime_type"; -STREAMANALYZER_EXPORT const string FieldRegister::filenameFieldName = "system.file_name"; -STREAMANALYZER_EXPORT const string FieldRegister::extensionFieldName = "system.file_extension"; -STREAMANALYZER_EXPORT const string FieldRegister::embeddepthFieldName = "system.depth"; -STREAMANALYZER_EXPORT const string FieldRegister::mtimeFieldName = "system.last_modified_time"; -STREAMANALYZER_EXPORT const string FieldRegister::sizeFieldName = "system.size"; +const string FieldRegister::pathFieldName = "system.location"; +const string FieldRegister::encodingFieldName = "content.charset"; +const string FieldRegister::mimetypeFieldName = "content.mime_type"; +const string FieldRegister::filenameFieldName = "system.file_name"; +const string FieldRegister::extensionFieldName = "system.file_extension"; +const string FieldRegister::embeddepthFieldName = "system.depth"; +const string FieldRegister::mtimeFieldName = "system.last_modified_time"; +const string FieldRegister::sizeFieldName = "system.size"; -STREAMANALYZER_EXPORT const string FieldRegister::defaultNamespace = "strigi."; +const string FieldRegister::defaultNamespace = "strigi."; FieldRegister::FieldRegister() { pathField = registerField(pathFieldName, stringType, 1, 0); Index: src/streams/fileinputstream.cpp =================================================================== --- src/streams/fileinputstream.cpp (revision 677989) +++ src/streams/fileinputstream.cpp (working copy) @@ -24,7 +24,7 @@ using namespace Strigi; -STREAMS_EXPORT const int32_t FileInputStream::defaultBufferSize = 1048576; +const int32_t FileInputStream::defaultBufferSize = 1048576; FileInputStream::FileInputStream(const char *filepath, int32_t buffersize) { if (filepath == 0) { --------------040102000503060907070107 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Kde-windows mailing list Kde-windows@kde.org https://mail.kde.org/mailman/listinfo/kde-windows --------------040102000503060907070107--