File tree Expand file tree Collapse file tree 3 files changed +17
-6
lines changed Expand file tree Collapse file tree 3 files changed +17
-6
lines changed Original file line number Diff line number Diff line change 3
3
\newcommand {\ghpr }{\href {https : // github.com / RcppCore / Rcpp / pull / # 1}{##1}}
4
4
\newcommand {\ghit }{\href {https : // github.com / RcppCore / Rcpp / issues / # 1}{##1}}
5
5
6
+ \section {Changes in Rcpp version 0.12.4 (2016 - 01 - XX )}{
7
+ \itemize {
8
+ \item Changes in Rcpp API :
9
+ \itemize {
10
+ \item \code {Nullable <> :: operator SEXP()} and
11
+ \code {Nullable <> :: get()} now also work for \code {const } objects
12
+ (PR \ghpr {417 }).
13
+ }
14
+ }
15
+ }
16
+
6
17
\section {Changes in Rcpp version 0.12.3 (2016 - 01 - 10 )}{
7
18
\itemize {
8
19
\item Changes in Rcpp API :
Original file line number Diff line number Diff line change @@ -76,7 +76,7 @@ namespace Rcpp {
76
76
*
77
77
* @throw 'not initialized' if object has not been set
78
78
*/
79
- inline operator SEXP () {
79
+ inline operator SEXP () const {
80
80
checkIfSet ();
81
81
return m_sexp;
82
82
}
@@ -86,7 +86,7 @@ namespace Rcpp {
86
86
*
87
87
* @throw 'not initialized' if object has not been set
88
88
*/
89
- inline SEXP get () {
89
+ inline SEXP get () const {
90
90
checkIfSet ();
91
91
return m_sexp;
92
92
}
Original file line number Diff line number Diff line change @@ -179,22 +179,22 @@ void test_stop_variadic() {
179
179
}
180
180
181
181
// [[Rcpp::export]]
182
- bool testNullableForNull (Nullable<NumericMatrix> M) {
182
+ bool testNullableForNull (const Nullable<NumericMatrix>& M) {
183
183
return M.isNull ();
184
184
}
185
185
186
186
// [[Rcpp::export]]
187
- bool testNullableForNotNull (Nullable<NumericMatrix> M) {
187
+ bool testNullableForNotNull (const Nullable<NumericMatrix>& M) {
188
188
return M.isNotNull ();
189
189
}
190
190
191
191
// [[Rcpp::export]]
192
- SEXP testNullableOperator (Nullable<NumericMatrix> M) {
192
+ SEXP testNullableOperator (const Nullable<NumericMatrix>& M) {
193
193
return M;
194
194
}
195
195
196
196
// [[Rcpp::export]]
197
- SEXP testNullableGet (Nullable<NumericMatrix> M) {
197
+ SEXP testNullableGet (const Nullable<NumericMatrix>& M) {
198
198
return M.get ();
199
199
}
200
200
You can’t perform that action at this time.
0 commit comments