mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-02-06 01:55:34 -05:00
9eef412b44
Added macro to deprecate symbols usage in a crossplatform way. Deprecated Request::mMethod and related stuff that make implementation more complex without advantage. Added /chat/{initiate_distant_chat, distant_chat_status, close_distant_chat} to libresapi. Solved subtle bug in ChatId::ChatId(std::string str) that caused zeroed DistantChatPeerId being created.
35 lines
1.4 KiB
C
35 lines
1.4 KiB
C
#pragma once
|
|
/*
|
|
* RetroShare deprecation macros
|
|
* Copyright (C) 2016 Gioacchino Mazzurco <gio@eigenlab.org>
|
|
*
|
|
* This program is free software: you can redistribute it and/or modify
|
|
* it under the terms of the GNU Affero General Public License as
|
|
* published by the Free Software Foundation, either version 3 of the
|
|
* License, or (at your option) any later version.
|
|
*
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU Affero General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU Affero General Public License
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
*/
|
|
|
|
#if __GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1)
|
|
# define RS_DEPRECATED __attribute__((__deprecated__))
|
|
#elif defined(_MSC_VER) && (_MSC_VER >= 1300)
|
|
# define RS_DEPRECATED __declspec(deprecated)
|
|
#else
|
|
# define RS_DEPRECATED
|
|
#endif
|
|
|
|
#if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 5)
|
|
# define RS_DEPRECATED_FOR(f) __attribute__((__deprecated__("Use '" #f "' instead")))
|
|
#elif defined(_MSC_FULL_VER) && (_MSC_FULL_VER > 140050320)
|
|
# define RS_DEPRECATED_FOR(f) __declspec(deprecated("is deprecated. Use '" #f "' instead"))
|
|
#else
|
|
# define RS_DEPRECATED_FOR(f) RS_DEPRECATED
|
|
#endif
|