in reply to Proving that Perl influenced JavaScript for WP
This is a link the current source of the Spidermonkey implementation of JS Arrays:
https://searchfox.org/mozilla-central/source/js/src/builtin/Array.cpp
Searching for the word "Perl" shows a list of "Perl-ish methods" like join , reverse, push , etc
/* Perl-ish methods. */ JS_INLINABLE_FN("join", array_join, 1, 0, ArrayJoin), JS_FN("reverse", array_reverse, 0, 0), JS_TRAMPOLINE_FN("sort", array_sort, 1, 0, ArraySort), JS_INLINABLE_FN("push", array_push, 1, 0, ArrayPush), JS_INLINABLE_FN("pop", array_pop, 0, 0, ArrayPop), JS_INLINABLE_FN("shift", array_shift, 0, 0, ArrayShift), JS_FN("unshift", array_unshift, 1, 0), JS_FNINFO("splice", array_splice, &array_splice_info, 2, 0),
. The corresponding Perl functions can be found in perlfunc
I'm sure a repo of JS 1.0 would show more detailed comments regarding Perl
Cheers Rolf
(addicted to the Perl Programming Language :)
see Wikisyntax for the Monastery
|
---|