| Index: src/scopes.h
|
| diff --git a/src/scopes.h b/src/scopes.h
|
| index 56a7ee97657148e430de38d8344f37cb5d2ec4cf..2b9ece2ad0bfabc6b0272242852d48b256ef4ea5 100644
|
| --- a/src/scopes.h
|
| +++ b/src/scopes.h
|
| @@ -467,6 +467,14 @@ class Scope: public ZoneObject {
|
| return variables_.Lookup(name) != NULL;
|
| }
|
|
|
| + bool IsDeclaredParameter(const AstRawString* name) {
|
| + // If IsSimpleParameterList is false, duplicate parameters are not allowed,
|
| + // however `arguments` may be allowed if function is not strict code. Thus,
|
| + // the assumptions explained above do not hold.
|
| + Variable* var = variables_.Lookup(name);
|
| + return var != NULL && params_.Contains(var);
|
| + }
|
| +
|
| // ---------------------------------------------------------------------------
|
| // Debugging.
|
|
|
|
|