Reorganized directory structure, fixed implicit cast