Skip to content

Commit f7a1399

Browse files
author
Qiang Kou
committed
for #345
1 parent ea7e715 commit f7a1399

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

inst/include/Rcpp/vector/Subsetter.h

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,14 @@ class SubsetProxy {
9797
return *this;
9898
}
9999

100+
template <int RTYPE_OTHER, template <class> class StoragePolicyOther,int RHS_RTYPE_OTHER, bool RHS_NA_OTHER, typename RHS_T_OTHER>
101+
SubsetProxy& operator=(const SubsetProxy<RTYPE_OTHER, StoragePolicyOther, RHS_RTYPE_OTHER, RHS_NA_OTHER, RHS_T_OTHER>& other) {
102+
103+
Vector<RTYPE, StoragePolicyOther> other_vec = other;
104+
*this = other_vec;
105+
return *this;
106+
}
107+
100108
operator Vector<RTYPE, StoragePolicy>() const {
101109
return get_vec();
102110
}

0 commit comments

Comments
 (0)