From d90e5978cfce31ac3b6d43280d8abe0780deb8dc Mon Sep 17 00:00:00 2001 From: Nate Gallaher Date: Mon, 30 Sep 2024 10:52:06 -0400 Subject: [PATCH] linter: Add std.clamp Added missing linter definition for std.clamp --- linter/internal/types/stdlib.go | 1 + 1 file changed, 1 insertion(+) diff --git a/linter/internal/types/stdlib.go b/linter/internal/types/stdlib.go index 82285f92..aa7f4c4c 100644 --- a/linter/internal/types/stdlib.go +++ b/linter/internal/types/stdlib.go @@ -72,6 +72,7 @@ func prepareStdlib(g *typeGraph) { "acos": g.newSimpleFuncType(numberType, "x"), "atan": g.newSimpleFuncType(numberType, "x"), "round": g.newSimpleFuncType(numberType, "x"), + "clamp": g.newSimpleFuncType(numberType, "x", "min", "max"), // Assertions and debugging "assertEqual": g.newSimpleFuncType(boolType, "a", "b"),