fn is_instance(&mut self, lhs: InstAddress, rhs: InstAddress) -> Result<bool, VmError> {
        let b = self.stack.address(rhs)?;
        let a = self.stack.address(lhs)?;

        let hash = match b {
            Value::Type(hash) => hash,
            _ => {
                return Err(VmError::from(VmErrorKind::UnsupportedIs {
                    value: a.type_info()?,
                    test_type: b.type_info()?,
                }));
            }
        };

        Ok(a.type_hash()? == hash)
    }
/// Internal implementation of the instance check.
Internal implementation of the instance check.
Internal implementation of the instance check .
fn is_instance(&mut self, lhs: InstAddress, rhs: InstAddress) -> Result<bool, VmError> {
        let b = self.stack.address(rhs)?;
        let a = self.stack.address(lhs)?;
        let hash = match b {
            Value::Type(hash) => hash,
            _ => {
                return Err(VmError::from(VmErrorKind::UnsupportedIs {
                    value: a.type_info()?,
                    test_type: b.type_info()?,
                }));
            }
        };
        Ok(a.type_hash()? == hash)
    }
fn is_instance ( & mut self , lhs : InstAddress , rhs : InstAddress ) -> Result < bool , VmError > { let b = self . stack . address ( rhs ) ? ; let a = self . stack . address ( lhs ) ? ; let hash = match b { Value :: Type ( hash ) => hash , _ => { return Err ( VmError :: from ( VmErrorKind :: UnsupportedIs { value : a . type_info ( ) ? , test_type : b . type_info ( ) ? , } ) ) ; } } ; Ok ( a . type_hash ( ) ? == hash ) }
Internal implementation of the instance check.
Internal implementation of the instance check .
&mut self
lhs
InstAddress
rhs
InstAddress
&mut self
lhs
InstAddress
rhs
InstAddress