Skip to content

´#else´ replaced with ´#endif´ causes ´#endif without #if´ in ´tx_port.h´ #545

@s-w-k-r

Description

@s-w-k-r

Description
In release v6.5.1.202602_rel, a change in ports/cortex_m4/gnu/inc/tx_port.h replaced an #else with #endif in the __set_basepri_value() block. This closes the #ifdef TX_PORT_USE_BASEPRI block prematurely, leaving a later, now-orphaned #endif without a matching #if. This breaks compilation. The same faulty change appears to have been applied across multiple ports, not just cortex_m4.

Error Message

src/rtos/eclipse-threadx/threadx/ports/cortex_m4/gnu/inc/tx_port.h:717:2: error: #endif without #if
  717 | #endif
Location
ports/cortex_m4/gnu/inc/tx_port.h (regression around lines 539–547; error surfaces at line 717)

Current (buggy) code

#ifdef TX_PORT_USE_BASEPRI
__attribute__( ( always_inline ) ) static inline void __set_basepri_value(unsigned int basepri_value)
{
    __asm__ volatile ("MSR  BASEPRI,%0 ": : "r" (basepri_value) : "memory");
}
#endif

__attribute__( ( always_inline ) ) static inline void __enable_interrupts(void)
{
    __asm__ volatile ("CPSIE  i": : : "memory");
}
#endif

Metadata

Metadata

Assignees

Labels

bugSomething isn't workinghardwareNew hardware or architecture support request

Type

No type
No fields configured for issues without a type.

Projects

Status
Done

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions