GDEF classes are not set for glyphs without anchors

I was updating a font I haven’t touched in a while, when I noticed that many substututions are broken. After some debugging it turned out because mark glyphs were not classified as marks in GDEF table.

It looks like Glyphs is now not setting glyph classes for any glyphs without anchors, neither base nor mark glyphs.

See this test font New Font 2.glyphs (1.5 KB), hamzaabove-ar has anchors, so both it and the composite alefHamzaabove-ar have GDEF classes, but the rest of the glyphs don’t.

Currently the GDEF mark classes are build from the mark (feature) classes.

But why is that? It used to be based on the glyph info, and this is breaking many fonts (I often use dummy empty glyphs and classify them as marks, and they has no anchors). The GDEF glyph classes are important as they control what glyphs are skipped with various lookup flags.

It was moved into feaKit by a college, I don’t remember why. I’ll need to get it back out.