From 81651a70bf8e8e45e829c7a1a2a7d7bd46bb805b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=80=E8=90=8C=E5=B0=8F=E6=B1=90?= Date: Wed, 5 Jan 2022 21:10:28 +0800 Subject: fix `not-yieldable` --- test/diagnostics/init.lua | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'test') diff --git a/test/diagnostics/init.lua b/test/diagnostics/init.lua index cfe29d04..58414b60 100644 --- a/test/diagnostics/init.lua +++ b/test/diagnostics/init.lua @@ -1460,6 +1460,16 @@ f(function () ---@async end) ]] +TEST [[ +local function f(...) + return ... +end + +f(1, function () ---@async + return nil +end) +]] + TEST [[ ---@nodiscard local function f() -- cgit v1.2.3