"mismatched character expecting '\n' " error when adding comment to .items file


I’m running openhabian (latest version) on my raspberry pi model 3. When I add an comment in my .items file I get the following message:

2018-03-23 08:15:09.806 [WARN ] [el.core.internal.ModelRepositoryImpl] - Configuration model ‘bulbs.items’ has errors, therefore ignoring it: [18,1]: mismatched character ‘\r’ expecting ‘\n’

The code in question(the comment is on line 18) looks like this:

Group    gLivingRoomLamp1Toggle	(gAllLightsToggle, gLivingRoomLights)
// sfg

Group:Switch				gDoorLamp1Toggle				"Lampe dør ON/OFF"			(gDoorLightsToggle)

If I remove the blank line after the comment the error would be “mismatched character ‘G’ expecting ‘\n’” instead. I am editing the file with Textwrangler on a Mac.

Appreciate the help.

This is to do with your text editor.
Does your editor has options like UTF8 format?
Try another editor. Use VSCode with the openhab plugin

Thanks for the quick reply! I tried xcode, and textedit earlier as well with the same issues. However using VSCode solved it!