https://github.com/eddelbuettel/rcppdate
R package providing date C++ library header files
https://github.com/eddelbuettel/rcppdate
Last synced: over 1 year ago
JSON representation
R package providing date C++ library header files
- Host: GitHub
- URL: https://github.com/eddelbuettel/rcppdate
- Owner: eddelbuettel
- Created: 2020-03-15T21:05:51.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2025-03-06T13:28:49.000Z (over 1 year ago)
- Last Synced: 2025-03-06T13:39:58.931Z (over 1 year ago)
- Language: C++
- Homepage:
- Size: 434 KB
- Stars: 10
- Watchers: 3
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: ChangeLog
Awesome Lists containing this project
README
## RcppDate: date C++ header library for R
[](https://github.com/eddelbuettel/rcppdate/actions?query=workflow%3Aci)
[](https://www.gnu.org/licenses/old-licenses/gpl-2.0.html)
[](https://cran.r-project.org/package=RcppDate)
[](https://cran.r-project.org/package=RcppDate)
[](https://www.r-pkg.org/pkg/RcppDate)
[](https://github.com/eddelbuettel/rcppdate)
### About
The [date](https://github.com/HowardHinnant/date) library by Howard Hinnant
offers extensive date and time functionality for the C++11, C++14 and C++17
standards. A slighly modified version of `date.h` has been accepted (along
with `tz.h`) as part of C++20.
This package regroups all header files from the upstream repository by Howard
Hinnant so that other R packages can use them in their C++ code.
### Example
There is _a lot_ of functionality in this library. As a teaser, consider these three
compile-time instantiations of `year_month_day` types:
```c++
constexpr auto x1 = 2015_y/March/22;
constexpr auto x2 = March/22/2015;
constexpr auto x3 = 22_d/March/2015;
```
See the file [inst/examples/year_month_day.cpp](inst/examples/year_month_day.cpp) for
the complete example, and the upstream documentation for full details.
### Limitations
The `tz.h` header requires compiled support from
[`tz.cpp`](https://github.com/HowardHinnant/date/blob/master/src/tz.cpp)
which is not currently included so that this remains a header-only library.
### See Also
The [date](https://github.com/HowardHinnant/date) repository and its links to
documentation.
### Author
[date](https://github.com/HowardHinnant/date) was written by Howard Hinnant.
This package was put together by Dirk Eddelbuettel
### License
The underlying library is MIT licensed.
The packaging and integrations is licensed under GPL (>= 2).