mirror of
https://gitlab.com/embeddable-common-lisp/ecl.git
synced 2026-01-24 13:31:58 -08:00
packages: accessors: allocate new objects
There were two fixme's which returned internal data structure (without copying it).
This commit is contained in:
parent
57d588116a
commit
9a1a4d48c8
1 changed files with 2 additions and 4 deletions
|
|
@ -900,17 +900,15 @@ cl_find_package(cl_object p)
|
|||
cl_object
|
||||
cl_package_name(cl_object p)
|
||||
{
|
||||
/* FIXME: name should be a fresh one */
|
||||
p = si_coerce_to_package(p);
|
||||
@(return p->pack.name);
|
||||
return cl_copy_seq(p->pack.name);
|
||||
}
|
||||
|
||||
cl_object
|
||||
cl_package_nicknames(cl_object p)
|
||||
{
|
||||
/* FIXME: list should be a fresh one */
|
||||
p = si_coerce_to_package(p);
|
||||
@(return p->pack.nicknames);
|
||||
return cl_copy_list(p->pack.nicknames);
|
||||
}
|
||||
|
||||
@(defun rename_package (pack new_name &o new_nicknames)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue