diff options
Diffstat (limited to 'node_modules/call-matcher/README.md')
-rw-r--r-- | node_modules/call-matcher/README.md | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/node_modules/call-matcher/README.md b/node_modules/call-matcher/README.md index b7ee0b28a..b5f110958 100644 --- a/node_modules/call-matcher/README.md +++ b/node_modules/call-matcher/README.md @@ -5,7 +5,6 @@ ECMAScript CallExpression matcher made from function/method signature [![Build Status][travis-image]][travis-url] [![NPM version][npm-image]][npm-url] -[![Dependency Status][depstat-image]][depstat-url] [![License][license-image]][license-url] @@ -135,7 +134,7 @@ Tests whether `node` matches the signature or not. Returns match result object representing whether `node` (and its `parentNode`) matches some argument of the signature or not. - Returns `null` if not matched. - - If matched, returns object like `{name: 'actual', kind: 'mandatory'}`, whose `name` is an argument name in the signature and `kind` is `'mandatory'` or `'optional'`. + - If matched, returns object like `{index: 0, name: 'actual', kind: 'mandatory'}`, whose `index` is an index of matched argument, `name` is an argument name in the signature and `kind` is `'mandatory'` or `'optional'`. `node` and `parentNode` should be AST node objects defined in [The ESTree Spec](https://github.com/estree/estree) (formerly known as [Mozilla SpiderMonkey Parser API](https://developer.mozilla.org/en-US/docs/SpiderMonkey/Parser_API)). @@ -147,7 +146,7 @@ Returns clone of callee AST object based on signature passed to `CallMatcher` fu ### var argSigs = matcher.argumentSignatures() -Returns array of argument signature objects based on signature passed to `CallMatcher` function. Returns array of objects like `[{name: 'actual', kind: 'mandatory'}]`, whose `name` is an argument name in the signature and `kind` is `'mandatory'` or `'optional'`. +Returns array of argument signature objects based on signature passed to `CallMatcher` function. Returns array of objects like `[{index: 0, name: 'actual', kind: 'mandatory'}]`, whose `index` is an index of matched argument, `name` is an argument name in the signature and `kind` is `'mandatory'` or `'optional'`. @@ -190,8 +189,5 @@ Licensed under the [MIT](https://github.com/twada/call-matcher/blob/master/MIT-L [travis-url]: https://travis-ci.org/twada/call-matcher [travis-image]: https://secure.travis-ci.org/twada/call-matcher.svg?branch=master -[depstat-url]: https://gemnasium.com/twada/call-matcher -[depstat-image]: https://gemnasium.com/twada/call-matcher.svg - [license-url]: https://github.com/twada/call-matcher/blob/master/MIT-LICENSE.txt [license-image]: https://img.shields.io/badge/license-MIT-brightgreen.svg |