laravel 执行 route:list时报错

问题描述

0.laravel版本 5.1LTS,php版本7.0

  1. 新增控制器方法并在routes.php文件中注册对应路由,访问路由,提示该Controller文件不存在

  2. 执行 php artisan route:list,显示

laravel cannot declare class [xxx], because the name is already in use

3.类引用情况

namespace App\Http\Controllers\xxx;

use App\Http\Controllers\Controller;
use App\Http\Requests\QueryXxxRequest;
use App\Models\xxx的model;
use Carbon\Carbon;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Config;
use Illuminate\Support\Facades\Session;

多方搜索无果,尝试过清除缓存

php artisan config:clear
php artisan cache:clear
php artisan view:clear
php artisan route:clear

均无效,请问各位大大有没有遇到过类似的问题,是如何解决的?

malphitee
修改的评论也不能少于六个字哦!