Strange error message, on encountering empty macro - Picaxe Editor 6.0.8.7

PhilHornby

Senior Member
Code:
      [COLOR=navy]#Macro [/COLOR][COLOR=black]GivesError
      [/COLOR][COLOR=navy]#endm[/COLOR]
"CHECK SYNTAX" gives a pair of strange error messages: EditorError3.png

(It probably goes without saying, but I do not have a file called: "C:\Revolution\PROJECTS\REVOLUT\Stamp\picaxepp\picaxepp\symbol.cpp")
 

Technical

Technical Support
Staff member
Macros substitute their code during their preprocessor run before compilation, so a completely empty macro doesn't make much sense. However we will make the error msg better.
 

PhilHornby

Senior Member
Not an error.

Well they make sense to me! ... I don't think any error message is needed.

The following versions can be used as a workaround:-
Code:
[COLOR=navy]#macro [/COLOR][COLOR=black]GivesNoError[/COLOR][COLOR=blue]()[/COLOR]
[COLOR=navy]#endm


#macro [/COLOR][COLOR=black]GivesNoErrorEither[/COLOR]

[COLOR=navy]#endm[/COLOR]
 
Last edited:

Technical

Technical Support
Staff member
The error message we were referring to is that all directives should be left aligned (no white space to the left of the #). This would have make the initial issue easier to understand.
 
Top