Skip to content

Commit 7c35c14

Browse files
committed
Correct cast to R_xlen_t (closes #1334)
1 parent b5f358a commit 7c35c14

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

ChangeLog

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
2024-09-29 Dirk Eddelbuettel <[email protected]>
2+
3+
* inst/include/Rcpp/vector/Vector.h: Correct cast to R_xlen_t
4+
15
2024-09-17 Dirk Eddelbuettel <[email protected]>
26

37
* DESCRIPTION (Version, Date): Roll micro version

inst/include/Rcpp/vector/Vector.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
// Vector.h: Rcpp R/C++ interface class library -- vectors
22
//
3-
// Copyright (C) 2010 - 2023 Dirk Eddelbuettel and Romain Francois
3+
// Copyright (C) 2010 - 2024 Dirk Eddelbuettel and Romain Francois
44
//
55
// This file is part of Rcpp.
66
//
@@ -331,7 +331,7 @@ class Vector :
331331
}
332332

333333
inline iterator begin() { return cache.get() ; }
334-
inline iterator end() { return cache.get() + static_cast<int>(size()) ; }
334+
inline iterator end() { return cache.get() + static_cast<R_xlen_t>(size()) ; }
335335
inline const_iterator begin() const{ return cache.get_const() ; }
336336
inline const_iterator end() const{ return cache.get_const() + size() ; }
337337
inline const_iterator cbegin() const{ return cache.get_const() ; }

0 commit comments

Comments
 (0)