From 5a10769cb41212ec4be501188690943bbd9496bd Mon Sep 17 00:00:00 2001 From: Ben Date: Wed, 7 Feb 2024 00:10:41 +0800 Subject: [PATCH] corrected contract annotation position. --- core/stdlib/std.ncl | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/core/stdlib/std.ncl b/core/stdlib/std.ncl index 008950a8f7..ca03505179 100644 --- a/core/stdlib/std.ncl +++ b/core/stdlib/std.ncl @@ -1325,6 +1325,7 @@ (fun start => RangeSecond start -> Codomain), IndexedArrayFun + | [| 'Index, 'Split |] -> Dyn -> Dyn | doc m%" **Warning**: this is an unstable item. It might be renamed, modified or deleted in any subsequent minor Nickel version. @@ -1379,15 +1380,13 @@ else value in - let contract - | [| 'Index, 'Split |] -> Dyn -> Dyn - = fun type label function => - DependentFun - ArrayIndexFirst - (fun index => ArrayIndexSecond type index -> Dyn) - label - function - in contract, + let contract = fun type label function => + DependentFun + ArrayIndexFirst + (fun index => ArrayIndexSecond type index -> Dyn) + label + function + in contract, ArraySliceFun | doc m%"