| Index: runtime/vm/dart_api_impl.cc
|
| ===================================================================
|
| --- runtime/vm/dart_api_impl.cc (revision 9727)
|
| +++ runtime/vm/dart_api_impl.cc (working copy)
|
| @@ -2734,8 +2734,7 @@
|
| ASSERT(func_kind == RawFunction::kFunction ||
|
| func_kind == RawFunction::kGetterFunction ||
|
| func_kind == RawFunction::kSetterFunction ||
|
| - func_kind == RawFunction::kConstructor ||
|
| - func_kind == RawFunction::kAbstract);
|
| + func_kind == RawFunction::kConstructor);
|
| }
|
| #endif
|
| return Api::NewHandle(isolate, func.raw());
|
| @@ -2776,7 +2775,7 @@
|
| if (func.IsNull()) {
|
| RETURN_TYPE_ERROR(isolate, function, Function);
|
| }
|
| - *is_abstract = (func.kind() == RawFunction::kAbstract);
|
| + *is_abstract = func.is_abstract();
|
| return Api::Success(isolate);
|
| }
|
|
|
| @@ -2824,13 +2823,7 @@
|
| if (func.IsNull()) {
|
| RETURN_TYPE_ERROR(isolate, function, Function);
|
| }
|
| - // TODO(turnidge): It would be nice if I could just use func.kind()
|
| - // to check for a getter function here, but unfortunately the only
|
| - // way to distinguish abstract getter functions is to use the name
|
| - // itself. Consider adding a RawFunction::kAbstractGetter type.
|
| - const String& func_name = String::Handle(isolate, func.name());
|
| - *is_getter = Field::IsGetterName(func_name);
|
| -
|
| + *is_getter = (func.kind() == RawFunction::kGetterFunction);
|
| return Api::Success(isolate);
|
| }
|
|
|
| @@ -2846,13 +2839,7 @@
|
| if (func.IsNull()) {
|
| RETURN_TYPE_ERROR(isolate, function, Function);
|
| }
|
| - // TODO(turnidge): It would be nice if I could just use func.kind()
|
| - // to check for a setter function here, but unfortunately the only
|
| - // way to distinguish abstract setter functions is to use the name
|
| - // itself. Consider adding a RawFunction::kAbstractSetter type.
|
| - const String& func_name = String::Handle(isolate, func.name());
|
| - *is_setter = Field::IsSetterName(func_name);
|
| -
|
| + *is_setter = (func.kind() == RawFunction::kSetterFunction);
|
| return Api::Success(isolate);
|
| }
|
|
|
|
|