From: Jacek Caban Subject: Re: [1/2] jscript: Support PROPERTYGET in Date Value Message-Id: <548DC089.7080306@codeweavers.com> Date: Sun, 14 Dec 2014 17:53:29 +0100 On 12/14/14 00:18, Alistair Leslie-Hughes wrote: > case INVOKE_PROPERTYGET: > + { > + DateInstance *date; > + > + if(!(date = date_this(jsthis))) > + return throw_type_error(ctx, JS_E_DATE_EXPECTED, NULL); It's guaranteed that jsthis is of DataInstance type in case of *_value functions, so there is no need to check that in runtime. You may simply cast it here. Jacek