mirror of
https://github.com/nim-lang/Nim.git
synced 2026-08-10 09:08:11 +00:00
Deploy to GitHub pages
This commit is contained in:
15
nimcache/runnableExamples/jscore_examples_1.nim
Normal file
15
nimcache/runnableExamples/jscore_examples_1.nim
Normal file
@@ -0,0 +1,15 @@
|
||||
#[
|
||||
autogenerated by docgen
|
||||
loc: /home/runner/work/Nim/Nim/lib/js/jscore.nim(133, 5)
|
||||
rdoccmd:
|
||||
]#
|
||||
import std/assertions
|
||||
import "/home/runner/work/Nim/Nim/lib/js/jscore.nim"
|
||||
{.line: ("/home/runner/work/Nim/Nim/lib/js/jscore.nim", 133, 5).}:
|
||||
assert ['a', 'b', 'c', 'd', 'e'].copyWithin(0, 3, 4) == @['d', 'b', 'c', 'd', 'e']
|
||||
assert ['a', 'b', 'c', 'd', 'e'].copyWithin(1, 3) == @['a', 'd', 'e', 'd', 'e']
|
||||
assert [1, 2, 3, 4, 5].copyWithin(-2) == @[1, 2, 3, 1, 2]
|
||||
assert [1, 2, 3, 4, 5].copyWithin(0, 3) == @[4, 5, 3, 4, 5]
|
||||
assert [1, 2, 3, 4, 5].copyWithin(0, 3, 4) == @[4, 2, 3, 4, 5]
|
||||
assert [1, 2, 3, 4, 5].copyWithin(-2, -3, -1) == @[1, 2, 3, 3, 4]
|
||||
|
||||
Reference in New Issue
Block a user