Skip to content

Commit

Permalink
refactor: complete slices category migration 🌱✨
Browse files Browse the repository at this point in the history
  • Loading branch information
42atomys committed May 8, 2024
1 parent 8e286dc commit 7190e02
Show file tree
Hide file tree
Showing 8 changed files with 1,279 additions and 789 deletions.
12 changes: 12 additions & 0 deletions NOTABLE_CHANGES_FROM_SPRIG_NOTES.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,3 +54,15 @@ In sprout this function support int32 and *time.Time and return the correct resu
### DateRound
In sprig When we pass a negative value, it will return the correct duration but in positive value.
In sprout When we pass a negative value, it will return the correct duration with in negative value.

### Append, Prepend, Concat, Chunk, Uniq, Compact, Slice, Without, Rest, Initial, Reverse
In sprig all these functions cause internal panic.
In sprout all these functions return empty slice when an error occurs.

### First, Last
In sprig all these functions cause internal panic.
In sprout all these functions return nil when an error occurs.

### MustAppend, MustPrepend, MustConcat, MustChunk, MustUniq, MustCompact, MustSlice, MustWithout, MustRest, MustInitial, MustReverse
In sprig all these functions cause segfault when lsit are nil.
In sprout all these functions return nil and an error when an error occurs.
1 change: 1 addition & 0 deletions alias.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ var bc_registerSprigFuncs = FunctionAliasMap{
"pathIsAbs": {"isAbs"}, //! Deprecated: Should use pathIsAbs instead
"expandEnv": {"expandenv"}, //! Deprecated: Should use expandEnv instead
"dateAgo": {"ago"}, //! Deprecated: Should use dateAgo instead
"strSlice": {"toStrings"}, //! Deprecated: Should use strSlice instead
}

//\ BACKWARDS COMPATIBILITY
Expand Down
Loading

0 comments on commit 7190e02

Please sign in to comment.