theKernel 10.0
Loading...
Searching...
No Matches
MkErrorC_Raise_RB_API

MkErrorC - various functions to 'raise' a MkErrorSMore...

+ Collaboration diagram for MkErrorC_Raise_RB_API:

Functions

static OT_ProcRet rbmkkernel_MkErrorC_NoRaise (MkErrorC_ARGS)
  Ruby: MkErrorC err.NoRaise() C-API
ignore the next return of MK_ERROR and do not raise an target-language-exception
 
static OT_ProcRet rbmkkernel_MkErrorC_AppendC (MkErrorC_ARGS)
  Ruby: err.AppendC(message:string) C-API
append the message to the MkErrorS::text
 
static OT_ProcRet rbmkkernel_MkErrorC_Raise (MkErrorC_ARGS)
  Ruby: err.Raise() C-API
convert an rbmkkernel error into an programming-language-error and raise afterwards. …
 
static OT_ProcRet rbmkkernel_MkErrorC_SetC (MkErrorC_ARGS)
  Ruby: err.SetC(message:string, ?callfunc:string="MK_NULL"?, ?errnum:int32=-1?) C-API
'set' and 'raise' the MkErrorC using a string-message and a errnum-number
 
static OT_ProcRet rbmkkernel_MkErrorC_PanicC (OtClass_ARGS)
  Ruby: (static) MkErrorC.PanicC(fmtobj:MkObjectC, callfunc:string, errnum:int32, message:string) C-API
do a panic with string as argument …
 
static OT_ProcRet rbmkkernel_MkErrorC_PanicDEFAULT (OtClass_ARGS)
  Ruby: (static) MkErrorC.PanicDEFAULT(?fmtobj:MkObjectC=nil?, ?callfunc:string="MK_NULL"?) C-API
make panic from MkErrorDEFAULT_RT …
 

Detailed Description

MkErrorC - various functions to 'raise' a MkErrorS

An error is "raised" by naming the MkErrorS::text and changing the MkErrorS::code to MK_ERROR.

Function Documentation

◆ rbmkkernel_MkErrorC_AppendC()

static OT_ProcRet rbmkkernel_MkErrorC_AppendC ( MkErrorC_ARGS )
static

Ruby: err.AppendC(message:string) C-API
append the message to the MkErrorS::text

Definition at line 470 of file MkErrorC_rb.c.

470 {
473 MK_STRN message = 0;
476 MkErrorAppendC (hdl, message);
478 end: MK_UNUSED /* LONG JUMP on error */
480}
#define OT_SETUP_ONEARG(d)
#define OT_CHECK_REQUIRED(val)
#define OT_retObj_SET_None
#define OT_retObj_RETURN
#define OT_CHECK_NOARGS
#define OT_CHECK_STRN(val)
#define OT_SETUP_hdl
Definition MkErrorC_rb.c:87
#define AppendC_doc
#define MkErrorAppendC(...)
#define MK_UNUSED
mark unnused variables and functions
const MK_STRB * MK_STRN
constant string pointer data-type

◆ rbmkkernel_MkErrorC_NoRaise()

static OT_ProcRet rbmkkernel_MkErrorC_NoRaise ( MkErrorC_ARGS )
static

Ruby: MkErrorC err.NoRaise() C-API
ignore the next return of MK_ERROR and do not raise an target-language-exception

Definition at line 457 of file MkErrorC_rb.c.

457 {
461 MK_ERR retVal = MkErrorNoRaise (hdl);
462 OT_retObj_SET_ERR(retVal);
463 end: MK_UNUSED /* LONG JUMP on error */
465}
#define OT_SETUP_NOARG(d)
#define OT_retObj_SET_ERR(nat)
#define NoRaise_doc
#define MkErrorNoRaise(...)
The data-type to store and handle the error-condition …

◆ rbmkkernel_MkErrorC_PanicC()

static OT_ProcRet rbmkkernel_MkErrorC_PanicC ( OtClass_ARGS )
static

Ruby: (static) MkErrorC.PanicC(fmtobj:MkObjectC, callfunc:string, errnum:int32, message:string) C-API
do a panic with string as argument …

Definition at line 515 of file MkErrorC_rb.c.

515 {
518 MK_OBJN fmtobj = NULL;
520 MK_STRN callfunc = NULL;
522 MK_I32 errnum = -1;
524 MK_STRN message = 0;
527 if (MkSysStringIsNULL(callfunc)) {callfunc = OT_GET_CALL_PROC;}
528 MkPanicC (fmtobj, callfunc, errnum, message);
530 end: MK_UNUSED /* LONG JUMP on error */
533}
#define OT_SETUP_VARARGS(min, max, d)
#define OT_CHECK_NI4(val)
#define OT_FRAME_CLEANUP
#define OT_GET_CALL_PROC
#define OT_CHECK_OPTIONAL(val)
#define OT_SETUP_hdl_static
Definition MkErrorC_rb.c:93
#define PanicC_doc
#define MkPanicC(...)
#define MK_NULL_YES
flag, allow NULL
signed int MK_I32
4 byte integer data-type
static bool MkSysStringIsNULL(MK_STRN str)
test if string is NULL or EMPTY …
#define OT_CHECK_OBJN(val, nullB)
object header …

◆ rbmkkernel_MkErrorC_PanicDEFAULT()

static OT_ProcRet rbmkkernel_MkErrorC_PanicDEFAULT ( OtClass_ARGS )
static

Ruby: (static) MkErrorC.PanicDEFAULT(?fmtobj:MkObjectC=nil?, ?callfunc:string="MK_NULL"?) C-API
make panic from MkErrorDEFAULT_RT …

Definition at line 536 of file MkErrorC_rb.c.

536 {
539 MK_OBJN fmtobj = NULL;
541 MK_STRN callfunc = NULL;
544 if (MkSysStringIsNULL(callfunc)) {callfunc = OT_GET_CALL_PROC;}
545 MkPanicDEFAULT (fmtobj, callfunc);
547 end: MK_UNUSED /* LONG JUMP on error */
550}
#define PanicDEFAULT_doc
#define MkPanicDEFAULT(...)

◆ rbmkkernel_MkErrorC_Raise()

static OT_ProcRet rbmkkernel_MkErrorC_Raise ( MkErrorC_ARGS )
static

Ruby: err.Raise() C-API
convert an rbmkkernel error into an programming-language-error and raise afterwards. …

Definition at line 483 of file MkErrorC_rb.c.

483 {
487 MkErrorC_Check(hdl,MkErrorRaise (hdl));
489 end: MK_UNUSED /* LONG JUMP on error */
491}
#define MkErrorC_Check(mng, PROC)
#define Raise_doc
#define MkErrorRaise(...)

◆ rbmkkernel_MkErrorC_SetC()

static OT_ProcRet rbmkkernel_MkErrorC_SetC ( MkErrorC_ARGS )
static

Ruby: err.SetC(message:string, ?callfunc:string="MK_NULL"?, ?errnum:int32=-1?) C-API
'set' and 'raise' the MkErrorC using a string-message and a errnum-number

Definition at line 494 of file MkErrorC_rb.c.

494 {
497 MK_STRN message = 0;
499 MK_STRN callfunc = NULL;
501 MK_I32 errnum = -1;
504 if (MkSysStringIsNULL(callfunc)) {callfunc = OT_GET_CALL_PROC;}
505 MkErrorC_Check(hdl,MkErrorSetC (hdl, message, callfunc, errnum));
507 end: MK_UNUSED /* LONG JUMP on error */
510}
#define SetC_doc
#define MkErrorSetC(...)