The reason why rm and mv are are first class citizens is because they correspond to libc/system calls (unlink and rename). "cp" has no libc/system call equivalent.
commit 76dc18c99a3b30f91d5f3a7007b972081af9bc09 Author: Martin Nilsson nilsson@fastmail.com Date: Fri Feb 9 19:24:29 2018 +0100
Put cp() in the global scope, as rm() and mv() are already there.
So polluting the global namespace with cp is not necessarily a logical step.
The mapping between libc calls and globals are only of historical interest by now, but I agree that cp() should not be made global without discussion.
Also note that the cp() hook lambda probably doesn't work as the author intended, as it will reinstall the predef every time it is used.
pike-devel@lists.lysator.liu.se