Trying to figure out how to do partial function application in Godot. Apparently, Godot has support for lambda functions:
func make_filter(max: int) -> Callable:
var l := func filter(val: int):
return val < max
return l
I used this accordingly to partially apply a function:
func clip_outlines()
# ...
# The solid area was untouched by the hole
elif result.any(func(area): return are_outlines_equal(solid, area)):
print ("\tsolid area untouched...")
pass