Beispiel #1
0
LispObject LispFunctions::cdr(const VectorOfLispObjects &lispObjects)
{
    LispObject lvalue = lispObjects[0];
    if (lvalue.valuesSize() < 2)
    {
        return LispObject::kNil;
    }
    LispObject result(lvalue);
    result.clear();
    return result;
}
Beispiel #2
0
LispObject LispFunctions::length(const VectorOfLispObjects &lispObjects)
{
    LispObject lvalue = lispObjects[0];
    return LispObject(TokenType::T_NUMBER, std::to_string(lvalue.valuesSize()));
}