aboutsummaryrefslogtreecommitdiff
path: root/environment.c
diff options
context:
space:
mode:
Diffstat (limited to 'environment.c')
-rw-r--r--environment.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/environment.c b/environment.c
index a6b68b91..cab39a0c 100644
--- a/environment.c
+++ b/environment.c
@@ -267,19 +267,27 @@ env_t *new_compilation_unit(CORD libname)
{"after", "DateTime$after", "func(dt:DateTime,seconds,minutes,hours=0.0,days,weeks,months,years=0,timezone=!Text -> DateTime)"},
{"date", "DateTime$date", "func(dt:DateTime,timezone=!Text -> Text)"},
+ {"day_of_month", "DateTime$day_of_month", "func(dt:DateTime,timezone=!Text -> Int)"},
+ {"day_of_week", "DateTime$day_of_week", "func(dt:DateTime,timezone=!Text -> Int)"},
+ {"day_of_year", "DateTime$day_of_year", "func(dt:DateTime,timezone=!Text -> Int)"},
{"format", "DateTime$format", "func(dt:DateTime,format=\"%Y-%m-%dT%H:%M:%S%z\",timezone=!Text -> Text)"},
{"from_unix_timestamp", "DateTime$from_unix_timestamp", "func(timestamp:Int64 -> DateTime)"},
- {"get", "DateTime$get", "func(dt:DateTime,year,month,day,hour,minute,second,nanosecond,weekday=!&Int,timezone=!Text)"},
{"get_local_timezone", "DateTime$get_local_timezone", "func(->Text)"},
+ {"hour", "DateTime$hour", "func(dt:DateTime,timezone=!Text -> Int)"},
{"hours_till", "DateTime$hours_till", "func(now,then:DateTime -> Num)"},
+ {"minute", "DateTime$minute", "func(dt:DateTime,timezone=!Text -> Int)"},
{"minutes_till", "DateTime$minutes_till", "func(now,then:DateTime -> Num)"},
+ {"month", "DateTime$month", "func(dt:DateTime,timezone=!Text -> Int)"},
+ {"nanosecond", "DateTime$nanosecond", "func(dt:DateTime,timezone=!Text -> Int)"},
{"new", "DateTime$new", "func(year,month,day:Int,hour,minute=0,second=0.0,timezone=!Text -> DateTime)"},
{"parse", "DateTime$parse", "func(text:Text, format=\"%Y-%m-%dT%H:%M:%S%z\" -> DateTime?)"},
{"relative", "DateTime$relative", "func(dt:DateTime,relative_to=DateTime.now(),timezone=!Text -> Text)"},
+ {"second", "DateTime$second", "func(dt:DateTime,timezone=!Text -> Int)"},
{"seconds_till", "DateTime$seconds_till", "func(now:DateTime,then:DateTime -> Num)"},
{"set_local_timezone", "DateTime$set_local_timezone", "func(timezone=!Text)"},
{"time", "DateTime$time", "func(dt:DateTime,seconds=no,am_pm=yes,timezone=!Text -> Text)"},
{"unix_timestamp", "DateTime$unix_timestamp", "func(dt:DateTime -> Int64)"},
+ {"year", "DateTime$year", "func(dt:DateTime,timezone=!Text -> Int)"},
)},
{"Path", Type(TextType, .lang="Path", .env=namespace_env(env, "Path")), "Text_t", "Text$info", TypedArray(ns_entry_t,
{"append", "Path$append", "func(path:Path, text:Text, permissions=0o644[32])"},