From ccc388f157eacfea6b5c44e1b6049a2bbeb44734 Mon Sep 17 00:00:00 2001 From: Phil Howard Date: Tue, 23 Feb 2021 22:56:44 +0000 Subject: [PATCH] rp2/mpthreadport.h: Cast core_state to _mp_state_thread_t. Required for user C++ code to build successfully against ports/rp2. Signed-off-by: Phil Howard --- ports/rp2/mpthreadport.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ports/rp2/mpthreadport.h b/ports/rp2/mpthreadport.h index 4583f6f539..5eb0bff396 100644 --- a/ports/rp2/mpthreadport.h +++ b/ports/rp2/mpthreadport.h @@ -41,7 +41,7 @@ static inline void mp_thread_set_state(struct _mp_state_thread_t *state) { } static inline struct _mp_state_thread_t *mp_thread_get_state(void) { - return core_state[get_core_num()]; + return (struct _mp_state_thread_t *)core_state[get_core_num()]; } static inline void mp_thread_mutex_init(mp_thread_mutex_t *m) {