Skip to content

Commit 8dd785b

Browse files
FieldProxy was incomplete
1 parent 706b699 commit 8dd785b

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
// Copyright (C) 2013 Romain Francois
2+
//
3+
// This file is part of Rcpp.
4+
//
5+
// Rcpp is free software: you can redistribute it and/or modify it
6+
// under the terms of the GNU General Public License as published by
7+
// the Free Software Foundation, either version 2 of the License, or
8+
// (at your option) any later version.
9+
//
10+
// Rcpp is distributed in the hope that it will be useful, but
11+
// WITHOUT ANY WARRANTY; without even the implied warranty of
12+
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13+
// GNU General Public License for more details.
14+
//
15+
// You should have received a copy of the GNU General Public License
16+
// along with Rcpp. If not, see <http://www.gnu.org/licenses/>.
17+
18+
#ifndef Rcpp_api_meat_FieldProxy_h
19+
#define Rcpp_api_meat_FieldProxy_h
20+
21+
namespace Rcpp {
22+
23+
template <typename CLASS>
24+
template <typename T>
25+
typename FieldProxyPolicy<CLASS>::FieldProxy& FieldProxyPolicy<CLASS>::FieldProxy::operator=( const T& rhs){
26+
set( wrap( rhs ) ) ;
27+
return *this ;
28+
}
29+
30+
template <typename CLASS>
31+
template <typename T>
32+
FieldProxyPolicy<CLASS>::FieldProxy::operator T() const {
33+
return as<T>(get());
34+
}
35+
36+
template <typename CLASS>
37+
template <typename T>
38+
FieldProxyPolicy<CLASS>::const_FieldProxy::operator T() const {
39+
return as<T>(get());
40+
}
41+
42+
}
43+
44+
#endif

0 commit comments

Comments
 (0)