-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
text/template: add a slice function to the predefined global functions
The new slice function returns the result of slicing its first argument by the following arguments. Thus {{slice x 1 3}} is, in Go syntax, x[1:3]. Each sliced item must be a string, slice, or array. Closed golang#30153 RELNOTE=yes Change-Id: I63188c422848cee3d383a64dc4d046e3a1767c63 Reviewed-on: https://go-review.googlesource.com/c/go/+/161762 Reviewed-by: Rob Pike <[email protected]>
- Loading branch information
Showing
3 changed files
with
114 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters