From 55a2bf76958c45c869f0a62c77c688bc9e55dfa5 Mon Sep 17 00:00:00 2001 From: Hisham Muhammad Date: Mon, 8 Jan 2024 18:25:45 -0300 Subject: [PATCH] standard library: add utf8 table --- tl.lua | 9 +++++++++ tl.tl | 9 +++++++++ 2 files changed, 18 insertions(+) diff --git a/tl.lua b/tl.lua index 376e2b735..3a19800dc 100644 --- a/tl.lua +++ b/tl.lua @@ -353,6 +353,15 @@ do unpack: function({A}, ? number, ? number): A... --[[needs_compat]] end + global record utf8 + char: function(number...): string + charpattern: string + codepoint: function(string, ? number, ? number, ? boolean): integer... + codes: function(string, ? boolean): (function(string, ? number): (integer, integer)) + len: function(string, ? number, ? number, ? boolean): integer + offset: function(string, number, ? number): integer + end + local record StandardLibrary enum CollectGarbageCommand "collect" diff --git a/tl.tl b/tl.tl index d5a5baa39..3c5ebd728 100644 --- a/tl.tl +++ b/tl.tl @@ -353,6 +353,15 @@ do unpack: function({A}, ? number, ? number): A... --[[needs_compat]] end + global record utf8 + char: function(number...): string + charpattern: string + codepoint: function(string, ? number, ? number, ? boolean): integer... + codes: function(string, ? boolean): (function(string, ? number): (integer, integer)) + len: function(string, ? number, ? number, ? boolean): integer + offset: function(string, number, ? number): integer + end + local record StandardLibrary enum CollectGarbageCommand "collect"