At the end of every line in Scintilla is a rectangle that may be painted in selection colour if that line end is selected. It is as wide as an average character.
When that line end is not selected the rectangle is drawn in the background colour of the line end which is often the global background colour so not noticeable. However, when there is a full line element like a line comment or preprocessor directive with a background colour, this is visible.
Example of some Lua code with a comment background colour at
In the example each line ends with its final graphical character - there is no line-end whitespace.
This is very old behaviour and may have been intentional but I'm unsure now whether it is reasonable. I am inclined to draw this area in the global background colour like the remainder of the line unless the style includes the EOLFilled option. The selection colour will still be applied over this when the line end is selected.