patch 8.0.0593: duplication of code for adding a list or dict return value

Problem:    Duplication of code for adding a list or dict return value.
Solution:   Add rettv_dict_set() and rettv_list_set(). (Yegappan Lakshmanan)
diff --git a/src/if_perl.xs b/src/if_perl.xs
index 076c5c6..2bf72c5 100644
--- a/src/if_perl.xs
+++ b/src/if_perl.xs
@@ -1136,9 +1136,7 @@
 		}
 	    }
 
-	    list->lv_refcount++;
-	    rettv->v_type	= VAR_LIST;
-	    rettv->vval.v_list	= list;
+	    rettv_list_set(rettv, list);
 	    break;
 	}
 	case SVt_PVHV:	/* dictionary */
@@ -1192,9 +1190,7 @@
 		}
 	    }
 
-	    dict->dv_refcount++;
-	    rettv->v_type	= VAR_DICT;
-	    rettv->vval.v_dict	= dict;
+	    rettv_dict_set(rettv, dict);
 	    break;
 	}
 	default:	/* not convertible */