Skip to content

Remove stray #endif directive - #2081

Closed
per1234 wants to merge 1 commit into
FastLED:masterfrom
per1234:stray-endif
Closed

per1234 wants to merge 1 commit into
FastLED:masterfrom
per1234:stray-endif

Conversation

@per1234

@per1234 per1234 commented Sep 13, 2025

Copy link
Copy Markdown
Contributor

This #endif directive does not have a companion #if directive, so it caused compilation of the library for any of the MGM240-based boards to fail:

In file included from c:\Users\per\Documents\Arduino\libraries\FastLED\src/led_sysdefs.h:62,
                 from c:\Users\per\Documents\Arduino\libraries\FastLED\src/FastLED.h:76,
                 from C:\Users\per\AppData\Local\Temp\.arduinoIDE-unsaved2025813-31520-l9rljz.363as\Blink\Blink.ino:6:
c:\Users\per\Documents\Arduino\libraries\FastLED\src/platforms/arm/mgm240/led_sysdefs_arm_mgm240.h:30:2: error: #endif without #if
   30 | #endif
      |  ^~~~~
exit status 1

Since the stray directive does not appear to have any intended purpose (perhaps it was originally part of a traditional include guard, which was later replaced by the #pragma once directive?), the bug is solved by the removal of the directive.

This `#endif` directive does not have a companion `#if` directive, so it caused compilation of the library for any of
the MGM240-based boards to fail:

```
In file included from c:\Users\per\Documents\Arduino\libraries\FastLED\src/led_sysdefs.h:62,
                 from c:\Users\per\Documents\Arduino\libraries\FastLED\src/FastLED.h:76,
                 from C:\Users\per\AppData\Local\Temp\.arduinoIDE-unsaved2025813-31520-l9rljz.363as\Blink\Blink.ino:6:
c:\Users\per\Documents\Arduino\libraries\FastLED\src/platforms/arm/mgm240/led_sysdefs_arm_mgm240.h:30:2: error: #endif without #if
   30 | #endif
      |  ^~~~~
exit status 1
```

Since the stray directive does not appear to have any intended purpose (perhaps it was originally part of a traditional
include guard, which was later replaced by the `#pragma once` directive?), the bug is solved by the removal of the
directive.
@zackees

zackees commented Sep 13, 2025

Copy link
Copy Markdown
Member

Fixed already.

@zackees zackees closed this Sep 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants