Bug? Error message only in B4i: "block is not a valid identifier"

Alessandro71

Well-Known Member
Licensed User
Longtime User
this simple (sample) sub causes an error only in B4i
all is fine in B4A and B4J
B4X:
Private Sub test(block As Int) As Int
    Return block + 1
End Sub
renaming "block" to "bblock" removes the message

sample project attached
 

Attachments

  • block.zip
    18.3 KB · Views: 198

Alessandro71

Well-Known Member
Licensed User
Longtime User
This is not a bug. The compiler looks for this and throws an error as this is a reserved keyword in OBJC and it will break the OBJC compiler.
shouldn't this type of keyword check be the same across all B4X products, so the resultant code will be portable?
i discovered this while compiling a running B4A app on B4i
 
Top