« Crop a two side page … | Home | 20 Years Monkeybread … »

MBS Syntax Colorizing saves the day!

We received an email today from Russell Watson and we like to share it with you:

For some reason in our solution some global variables were not being defined …

Where we always define 3 debugging variables ...



… for some reason only one was being defined:



What’s up?

Having first checked everywhere, that three global variables were being defined, we finally got on the track of the bug thanks to the MBS plugin syntax coloring, which was showing an ‘anomaly’ in one of the Let definitions:



Why is the first $ black?

Inspecting the DDR with a text editor which displays control characters (Textmate 2) gave us the final clue:



In the middle of the calculation, just in front of the $$ variable name there are UTF-16 BOM-characters to be found!

(A BOM is a Byte-Order-Mark which usually is only to be found at the very start of a UTF-16 text file, as can be seen when you look at a UTF-16 text file with a hex-editor, for example a DDR file:



The FF identifies the low byte and the FE identifies the high byte … thus the U+FEFF in the editor is the unicode BOM code point)

Editing the calculation to remove and re-enter the whitespace and the first $ symbol cleared the problem:



MBS Plugin happy = We’re happy !

Thank you MBS!
Thank you Christian Schmitz!

If you have stories to share, please let us know.
28 02 20 - 18:33