comparison src/if_py_both.h @ 3636:0e9b2622c94a v7.3.578

updated for version 7.3.578 Problem: Misplaced declaration. Solution: Move declaration to start of block.
author Bram Moolenaar <bram@vim.org>
date Fri, 29 Jun 2012 16:19:50 +0200
parents c052f3b79b99
children 80ed6aa7b9eb
comparison
equal deleted inserted replaced
3635:e57accfea24e 3636:0e9b2622c94a
816 816
817 di = dict_find(d, key, -1); 817 di = dict_find(d, key, -1);
818 818
819 if (valObject == NULL) 819 if (valObject == NULL)
820 { 820 {
821 hashitem_T *hi;
822
821 if (di == NULL) 823 if (di == NULL)
822 { 824 {
823 PyErr_SetString(PyExc_IndexError, _("no such key in dictionary")); 825 PyErr_SetString(PyExc_IndexError, _("no such key in dictionary"));
824 return -1; 826 return -1;
825 } 827 }
826 hashitem_T *hi = hash_find(&d->dv_hashtab, di->di_key); 828 hi = hash_find(&d->dv_hashtab, di->di_key);
827 hash_remove(&d->dv_hashtab, hi); 829 hash_remove(&d->dv_hashtab, hi);
828 dictitem_free(di); 830 dictitem_free(di);
829 return 0; 831 return 0;
830 } 832 }
831 833
832 if (ConvertFromPyObject(valObject, &tv) == -1) 834 if (ConvertFromPyObject(valObject, &tv) == -1)
833 {
834 return -1; 835 return -1;
835 }
836 836
837 if (di == NULL) 837 if (di == NULL)
838 { 838 {
839 di = dictitem_alloc(key); 839 di = dictitem_alloc(key);
840 if (di == NULL) 840 if (di == NULL)