示例#1
0
文件: error.c 项目: Z-Shang/Gauche
static ScmObj message_allocate(ScmClass *klass, ScmObj initargs)
{
    ScmError *e = SCM_ALLOCATE(ScmError, klass);
    SCM_SET_CLASS(e, klass);
    e->message = SCM_FALSE;     /* would be set by initialize */
    return SCM_OBJ(e);
}
示例#2
0
文件: error.c 项目: Z-Shang/Gauche
static ScmObj compound_allocate(ScmClass *klass, ScmObj initargs)
{
    ScmCompoundCondition *e = SCM_ALLOCATE(ScmCompoundCondition, klass);
    SCM_SET_CLASS(e, klass);
    e->conditions = SCM_NIL;
    return SCM_OBJ(e);
}
示例#3
0
文件: signal.c 项目: Z-Shang/Gauche
ScmObj sigset_allocate(ScmClass *klass, ScmObj initargs)
{
    ScmSysSigset *s = SCM_ALLOCATE(ScmSysSigset, klass);
    SCM_SET_CLASS(s, klass);
    sigemptyset(&s->set);
    return SCM_OBJ(s);
}
示例#4
0
文件: error.c 项目: Z-Shang/Gauche
static ScmObj porterror_allocate(ScmClass *klass, ScmObj initargs)
{
    ScmPortError *e = SCM_ALLOCATE(ScmPortError, klass);
    SCM_SET_CLASS(e, klass);
    e->common.message = SCM_FALSE; /* set by initialize */
    e->port = NULL;                /* set by initialize */
    return SCM_OBJ(e);
}
示例#5
0
文件: error.c 项目: Z-Shang/Gauche
static ScmObj sigerror_allocate(ScmClass *klass, ScmObj initargs)
{
    ScmUnhandledSignalError *e = SCM_ALLOCATE(ScmUnhandledSignalError, klass);
    SCM_SET_CLASS(e, klass);
    e->common.message = SCM_FALSE; /* set by initialize */
    e->signal = 0;                 /* set by initialize */
    return SCM_OBJ(e);
}
示例#6
0
文件: error.c 项目: Z-Shang/Gauche
static ScmObj syserror_allocate(ScmClass *klass, ScmObj initargs)
{
    ScmSystemError *e = SCM_ALLOCATE(ScmSystemError, klass);
    SCM_SET_CLASS(e, klass);
    e->common.message = SCM_FALSE; /* set by initialize */
    e->error_number = 0;           /* set by initialize */
    return SCM_OBJ(e);
}
示例#7
0
static ScmObj objc_error_allocate(ScmClass *klass, ScmObj initargs)
{
    ScmObjCError *err = SCM_ALLOCATE(ScmObjCError, klass);
    SCM_SET_CLASS(err, klass);
    err->name = SCM_FALSE;
    err->reason = SCM_FALSE;

    SCM_RETURN(SCM_OBJ(err));
}