nixfiles/libs/core/lib/null/default.nix
Sebastian Walz 9f7b02e1cd
Tohu vaBohu
2023-04-03 14:38:02 +02:00

17 lines
332 B
Nix

{ intrinsics, type, ... }:
type "null"
{
isInstanceOf = value: value == null;
isPrimitive = true;
default
= value:
other:
if value != null
then
value
else
other;
inherit(intrinsics) null;
}