Closed georgyangelov closed 8 years ago
I think that's all of them. Should be ready for review :smiley:
Awesome, so excited to review this!
This looks really solid. I'm curious about the dereference issue, but not enough to hold it up!
They shouldn't be needed. Don't really know what I was thinking :)
Actually, I tried removing them, and it was getting confused between the methods that had name keys, and the integer keys, probably because of operator VALUE()
. My guess is that VALUE
can be constructed from an int32_t
and so it doesn't know whether, for the Name
object, to convert to VALUE
or v8::Local<v8::Name>
(just a guess)
I'm trying to tackle exception handling and v8::TryCatch
and v8::StackTrace
. Any chance you could look at finishing out Template
, ObjectTemplate
and FunctionTemplate
. With those out of the way, we should have everything we need from the C api to get the entire test suite passing again.
I will look at the templates.
In this branch I put the Object method implementations.
Currently implemented:
SetAccessorProperty
GetOwnPropertyAccessor
GetPropertyAttributes
DefineOwnProperty
CreateDataProperty
GetConstructorName
InternalFieldCount
GetInternalField
SetInternalField
HasOwnProperty
HasRealNamedProperty
HasRealIndexedProperty
HasRealNamedCallbackProperty
GetRealNamedPropertyInPrototypeChain
GetRealNamedProperty
GetRealNamedPropertyAttributes
GetRealNamedPropertyAttributesInPrototypeChain
HasNamedLookupInterceptor
HasIndexedLookupInterceptor
SetHiddenValue
GetHiddenValue
DeleteHiddenValue
Clone
CreationContext
IsCallable
CallAsFunction
CallAsConstructor
Also, I added a few RSpec matchers for a more convenient use of
Maybe
instances:expect(a).to eq_just b
<=>a.IsJust && a.FromJust == b
expect(a).to be_successful
<=>a.IsJust && a.FromJust
expect(a).to strict_eq b
<=> if a is Maybe:a.IsJust && a.FromJust.StrictEquals(b)
; elsea.StrictEquals(b)
expect(a).to v8_eq b
<=> same as above but forEquals
instead ofStrictEquals