File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -894,13 +894,13 @@ class Vector :
894894 iterator target_it = target.begin () ;
895895
896896 SEXP names = RCPP_GET_NAMES (Storage::get__ ()) ;
897- iterator result ;
897+ int result = 0 ;
898898 if ( Rf_isNull (names) ){
899899 int i=0 ;
900900 for ( ; it < first; ++it, ++target_it, i++ ){
901901 *target_it = *it ;
902902 }
903- result = begin () + i + 1 ;
903+ result = i ;
904904 for ( it = last ; it < this_end; ++it, ++target_it ){
905905 *target_it = *it ;
906906 }
@@ -911,7 +911,7 @@ class Vector :
911911 *target_it = *it ;
912912 SET_STRING_ELT ( newnames, i, STRING_ELT (names, i ) );
913913 }
914- result = begin () + i + 1 ;
914+ result = i ;
915915 for ( it = last ; it < this_end; ++it, ++target_it, i++ ){
916916 *target_it = *it ;
917917 SET_STRING_ELT ( newnames, i, STRING_ELT (names, i + nremoved ) );
@@ -920,7 +920,7 @@ class Vector :
920920 }
921921 Storage::set__ ( target.get__ () ) ;
922922
923- return result ;
923+ return begin () + result ;
924924
925925 }
926926
You can’t perform that action at this time.
0 commit comments