mirror of
https://github.com/peklaiho/madlisp.git
synced 2024-11-26 15:14:12 +00:00
compare symbols using name
This commit is contained in:
parent
212c0780fd
commit
a34d528d80
@ -4,6 +4,7 @@ namespace MadLisp\Lib;
|
|||||||
use MadLisp\Collection;
|
use MadLisp\Collection;
|
||||||
use MadLisp\CoreFunc;
|
use MadLisp\CoreFunc;
|
||||||
use MadLisp\Env;
|
use MadLisp\Env;
|
||||||
|
use MadLisp\Symbol;
|
||||||
|
|
||||||
class Compare implements ILib
|
class Compare implements ILib
|
||||||
{
|
{
|
||||||
@ -44,7 +45,9 @@ class Compare implements ILib
|
|||||||
|
|
||||||
private function getValue($a)
|
private function getValue($a)
|
||||||
{
|
{
|
||||||
if ($a instanceof Collection) {
|
if ($a instanceof Symbol) {
|
||||||
|
return $a->getName();
|
||||||
|
} elseif ($a instanceof Collection) {
|
||||||
return $a->getData();
|
return $a->getData();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user