Missing exception description - how about:

    if (!is<object>()) throw type_mismatch("type mismatch! object element query attempted on non-object value");