Fixed the finding of classes to only return complete declarations.

Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>