If you look up error 10998 in the fpc source, it seems to happen when there's an unexpected condition reading the symbol table. I don't really know much about the symbol table though.