编辑代码

function Parent(a) {
    //console.log(args.concat(Array.prototype.slice.call(arguments)))
    const args = [...arguments].slice(1)
    console.log(args.concat(...arguments))
    //console.log(Array.prototype.slice.call(arguments))
    this.name = 'parent';
    this.play = [1, 2, 3];
}

//Parent(1,2,3,'a',[2,5,7])

let mybind = function(context, ...args) {
    // if (typeof this !== 'function') {
    //     throw new Error("Type Error");
    //   }
    console.log(arguments)
    var self = this
    var fbound = function() {
        console.log(args)
        console.log(Array.prototype.slice.call(arguments))
        console.log(args.concat(Array.prototype.slice.call(arguments)))
        //self.apply(this instanceof self ? this : context, args.concat(Array.prototype.slice.call(arguments)));
    }
    if(this.prototype) {
        fbound.prototype = Object.create(this.prototype)
    }
    return fbound
}

mybind(Parent,1)(2,3,'a')