Skip to content

Commit

Permalink
Merge pull request #2479 from geky/deprecated-until
Browse files Browse the repository at this point in the history
Updated deprecation notices to match branch names
  • Loading branch information
0xc0170 authored Aug 18, 2016
2 parents bdb4ab9 + b12c27c commit 64a30a0
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
4 changes: 2 additions & 2 deletions TESTS/mbedmicro-mbed/attributes/attributes.c
Original file line number Diff line number Diff line change
Expand Up @@ -137,11 +137,11 @@ int testDeprecatedUsed() {
return 0;
}

MBED_DEPRECATED_SINCE("v3.14", "this message should not be displayed")
MBED_DEPRECATED_SINCE("mbed-os-3.14", "this message should not be displayed")
void testDeprecatedSinceUnused();
void testDeprecatedSinceUnused() { }

MBED_DEPRECATED_SINCE("v3.14", "this message should be displayed")
MBED_DEPRECATED_SINCE("mbed-os-3.14", "this message should be displayed")
int testDeprecatedSinceUsed();
int testDeprecatedSinceUsed() {
return 0;
Expand Down
8 changes: 4 additions & 4 deletions hal/api/FunctionPointer.h
Original file line number Diff line number Diff line change
Expand Up @@ -29,13 +29,13 @@ namespace mbed {
template <typename R, typename A1>
class FunctionPointerArg1 : public Callback<R(A1)> {
public:
MBED_DEPRECATED_SINCE("v5.1",
MBED_DEPRECATED_SINCE("mbed-os-5.1",
"FunctionPointerArg1<R, A> has been replaced by Callback<R(A)>")
FunctionPointerArg1(R (*function)(A1) = 0)
: Callback<R(A1)>(function) {}

template<typename T>
MBED_DEPRECATED_SINCE("v5.1",
MBED_DEPRECATED_SINCE("mbed-os-5.1",
"FunctionPointerArg1<R, A> has been replaced by Callback<R(A)>")
FunctionPointerArg1(T *object, R (T::*member)(A1))
: Callback<R(A1)>(object, member) {}
Expand All @@ -48,13 +48,13 @@ class FunctionPointerArg1 : public Callback<R(A1)> {
template <typename R>
class FunctionPointerArg1<R, void> : public Callback<R()> {
public:
MBED_DEPRECATED_SINCE("v5.1",
MBED_DEPRECATED_SINCE("mbed-os-5.1",
"FunctionPointer has been replaced by Callback<void()>")
FunctionPointerArg1(R (*function)() = 0)
: Callback<R()>(function) {}

template<typename T>
MBED_DEPRECATED_SINCE("v5.1",
MBED_DEPRECATED_SINCE("mbed-os-5.1",
"FunctionPointer has been replaced by Callback<void()>")
FunctionPointerArg1(T *object, R (T::*member)())
: Callback<R()>(object, member) {}
Expand Down
2 changes: 1 addition & 1 deletion hal/api/toolchain.h
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@
* @code
* #include "toolchain.h"
*
* MBED_DEPRECATED_SINCE("v5.1", "don't foo any more, bar instead")
* MBED_DEPRECATED_SINCE("mbed-os-5.1", "don't foo any more, bar instead")
* void foo(int arg);
* @endcode
*/
Expand Down
2 changes: 1 addition & 1 deletion rtos/rtos/RtosTimer.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class RtosTimer {
@param argument argument to the timer call back function. (default: NULL)
@deprecated Replaced with RtosTimer(Callback<void()>, os_timer_type)
*/
MBED_DEPRECATED_SINCE("v5.1",
MBED_DEPRECATED_SINCE("mbed-os-5.1",
"Replaced with RtosTimer(Callback<void()>, os_timer_type)")
RtosTimer(void (*func)(void const *argument), os_timer_type type=osTimerPeriodic, void *argument=NULL) {
constructor(mbed::Callback<void()>(argument, (void (*)(void *))func), type);
Expand Down
8 changes: 4 additions & 4 deletions rtos/rtos/Thread.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ class Thread {
The explicit Thread::start member function should be used to spawn
a thread.
*/
MBED_DEPRECATED_SINCE("v5.1",
MBED_DEPRECATED_SINCE("mbed-os-5.1",
"Thread-spawning constructors hide errors and may lead to complex "
"program state when a thread is declared")
Thread(mbed::Callback<void()> task,
Expand All @@ -83,7 +83,7 @@ class Thread {
a thread.
*/
template <typename T>
MBED_DEPRECATED_SINCE("v5.1",
MBED_DEPRECATED_SINCE("mbed-os-5.1",
"Thread-spawning constructors hide errors and may lead to complex "
"program state when a thread is declared")
Thread(T *obj, void (T::*method)(),
Expand All @@ -109,7 +109,7 @@ class Thread {
a thread.
*/
template <typename T>
MBED_DEPRECATED_SINCE("v5.1",
MBED_DEPRECATED_SINCE("mbed-os-5.1",
"Thread-spawning constructors hide errors and may lead to complex "
"program state when a thread is declared")
Thread(T *obj, void (*method)(T *),
Expand All @@ -134,7 +134,7 @@ class Thread {
The explicit Thread::start member function should be used to spawn
a thread.
*/
MBED_DEPRECATED_SINCE("v5.1",
MBED_DEPRECATED_SINCE("mbed-os-5.1",
"Thread-spawning constructors hide errors and may lead to complex "
"program state when a thread is declared")
Thread(void (*task)(void const *argument), void *argument=NULL,
Expand Down

0 comments on commit 64a30a0

Please sign in to comment.