php7跑laravel5.0报错,异常Carbon::createFromFormat()

异常:Declaration of Carbon\Carbon::createFromFormat() should be compatible with DateTime::createFromFormat($format, $time, DateTimeZone $object = NULL)

解决:

修改:vendor/nesbot/carbon/src/Carbon/Carbon.php

第380行为:

public static function createFromFormat($format, $time,DateTimeZone $tz = null)

仅用于php7测试,这样php54是会出错的,所以测完php7还要改回来。