From f8463a374991c80d47d2acdf51dea6c1e4f7aaec Mon Sep 17 00:00:00 2001 From: bandzaw Date: Mon, 19 Mar 2018 23:15:40 +0100 Subject: [PATCH] Updated Examples and Recipes (markdown) --- Examples-and-Recipes.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Examples-and-Recipes.md b/Examples-and-Recipes.md index f230a22..563cab4 100644 --- a/Examples-and-Recipes.md +++ b/Examples-and-Recipes.md @@ -2384,7 +2384,7 @@ It isn't the most friendly code to have to write. But on the other hand, it giv More complex (and expensive) policies could track reference count usage for each tzdb and delete only when that reference count drops to zero. It is completely implementable externally without any privileged hooks into `"tz.h"`. This design is motivated by the "don't pay for what you don't use" philosophy. -### The current local time +### Converting from Unix Time to date::year_month_day (by [tommy bandzaw](https://github.com/bandzaw)) When working with APIs that gives you a timestamp as a plain integer, signed or not, for example a Unix Time, and you want to use it with chrono/date/time calculations, here's what one can do (instead of using the time_t & localtime):