fix(frontends/lean/inductive_cmd): improve name resolution in inductive
command

The new test demonstrates the problem being fixed by this commit
fix(frontends/lean/elaborator): more robust support for coercions to
function-class that contains implicit arguments
refactor(library/logic): move files in classes directory to core
refactor(library): rename algebra directory to struc, move categories.lean to algebra
fix(tests/lean/interactive): adjust test to library reorg
fix(tests/lean/interactive): adjust test to library reorg