# isArguments
# Description
判断是否为arguments
# Params
value
# Return
Boolean
# Depend
import getTag from './.internal/getTag.js'
import isObjectLike from './isObjectLike.js'
# Code
function isArguments(value) {
return isObjectLike(value) && getTag(value) == '[object Arguments]'
}
# Analyze
如果 value 为 类对象(isObjectLike(value))并且 Object.prototype.toString.call(value)' 返回的类型为 '[object Arguments]',那么就是一个类 arguments 对象
# Remark
(function () {
getTag(arguments)
})() // ‘[object Arguments]’
# Example
isArguments(1) // false
isArguments({a:1}) // false
(function(){
isArguments(arguments)
})() // true