#include <Log.d>
#include <__oo2c.h>
#include <setjmp.h>

OOC_CHAR8 Log__Done(void) {
  register OOC_INT64 i0;

  i0 = (OOC_INT64)Log__writer;
  i0 = (OOC_INT64)*(OOC_INT64*)(_check_pointer(i0, 1349));
  return (i0==0);
  ;
}

void Log__ClearError(void) {
  register OOC_INT64 i0;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 1427)))), TextRider__WriterDesc_ClearError)),TextRider__WriterDesc_ClearError)((TextRider__Writer)i0);
  return;
  ;
}

void Log__SetWriter(TextRider__Writer w) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)w;
  i1 = i0==(OOC_INT64)0;
  if (i1) goto l3;
  Log__writer = (TextRider__Writer)i0;
  goto l4;
l3:
  i0 = (OOC_INT64)StdChannels__stderr;
  i0 = (OOC_INT64)TextRider__ConnectWriter((Channel__Channel)i0);
  Log__writer = (TextRider__Writer)i0;
l4:
  return;
  ;
}

void Log__Flush(void) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)Log__writer;
  i1 = (OOC_INT64)*(OOC_INT64*)((_check_pointer(i0, 1939))+24);
  i0 = (OOC_INT64)*(OOC_INT64*)((_check_pointer(i0, 1939))+24);
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i1, 1945)))), Channel__ChannelDesc_Flush)),Channel__ChannelDesc_Flush)((Channel__Channel)i0);
  return;
  ;
}

void Log__Char(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_CHAR8 ch) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 2043)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 2074)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  i1 = ch;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 2106)))), TextRider__WriterDesc_WriteChar)),TextRider__WriterDesc_WriteChar)((TextRider__Writer)i0, i1);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 2134)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__String(const OOC_CHAR8 msg[], OOC_LEN msg_0d, const OOC_CHAR8 s[], OOC_LEN s_0d) {
  register OOC_INT64 i0;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 2253)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 2284)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 2316)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)s, s_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 2345)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__LString(const OOC_CHAR8 msg[], OOC_LEN msg_0d, const OOC_CHAR16 s[], OOC_LEN s_0d) {
  register OOC_INT64 i0,i1,i2;
  OOC_INT32 i;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 2849)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 2880)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i = 0;
  i0 = *(OOC_UINT16*)((OOC_INT64)s+(_check_index(0, s_0d, OOC_UINT32, 2926))*2);
  i0 = i0!=0u;
  if (!i0) goto l42;
  i0=0;
l3_loop:
  i1 = *(OOC_UINT16*)((OOC_INT64)s+(_check_index(i0, s_0d, OOC_UINT32, 2953))*2);
  i1 = i1!=0u;
  if (i1) goto l6;
  i1=0u;
  goto l8;
l6:
  i1 = *(OOC_UINT16*)((OOC_INT64)s+(_check_index(i0, s_0d, OOC_UINT32, 2967))*2);
  i1 = (OOC_UINT16)i1<=(OOC_UINT16)255u;
  
l8:
  if (!i1) goto l20;
l11_loop:
  i1 = (OOC_INT64)Log__writer;
  i2 = *(OOC_UINT16*)((OOC_INT64)s+(_check_index(i0, s_0d, OOC_UINT32, 3024))*2);
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i1, 3003)))), TextRider__WriterDesc_WriteChar)),TextRider__WriterDesc_WriteChar)((TextRider__Writer)i1, i2);
  i0 = i0+1;
  i = i0;
  i1 = *(OOC_UINT16*)((OOC_INT64)s+(_check_index(i0, s_0d, OOC_UINT32, 2953))*2);
  i1 = i1!=0u;
  if (i1) goto l14;
  i1=0u;
  goto l16;
l14:
  i1 = *(OOC_UINT16*)((OOC_INT64)s+(_check_index(i0, s_0d, OOC_UINT32, 2967))*2);
  i1 = (OOC_UINT16)i1<=(OOC_UINT16)255u;
  
l16:
  if (i1) goto l11_loop;
l20:
  i1 = *(OOC_UINT16*)((OOC_INT64)s+(_check_index(i0, s_0d, OOC_UINT32, 3072))*2);
  i1 = i1!=0u;
  if (i1) goto l23;
  i1=0u;
  goto l25;
l23:
  i1 = *(OOC_UINT16*)((OOC_INT64)s+(_check_index(i0, s_0d, OOC_UINT32, 3086))*2);
  i1 = (OOC_UINT16)i1>(OOC_UINT16)255u;
  
l25:
  if (!i1) goto l37;
l28_loop:
  i1 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i1, 3121)))), TextRider__WriterDesc_WriteChar)),TextRider__WriterDesc_WriteChar)((TextRider__Writer)i1, 63u);
  i0 = i0+1;
  i = i0;
  i1 = *(OOC_UINT16*)((OOC_INT64)s+(_check_index(i0, s_0d, OOC_UINT32, 3072))*2);
  i1 = i1!=0u;
  if (i1) goto l31;
  i1=0u;
  goto l33;
l31:
  i1 = *(OOC_UINT16*)((OOC_INT64)s+(_check_index(i0, s_0d, OOC_UINT32, 3086))*2);
  i1 = (OOC_UINT16)i1>(OOC_UINT16)255u;
  
l33:
  if (i1) goto l28_loop;
l37:
  i1 = *(OOC_UINT16*)((OOC_INT64)s+(_check_index(i0, s_0d, OOC_UINT32, 2926))*2);
  i1 = i1!=0u;
  if (i1) goto l3_loop;
l42:
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3185)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__Object(const OOC_CHAR8 msg[], OOC_LEN msg_0d, Object__Object obj) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3295)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3326)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  i1 = (OOC_INT64)obj;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3358)))), TextRider__WriterDesc_WriteObject)),TextRider__WriterDesc_WriteObject)((TextRider__Writer)i0, (Object__Object)i1);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3389)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__Bool(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_CHAR8 _bool) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3494)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3525)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  i1 = _bool;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3557)))), TextRider__WriterDesc_WriteBool)),TextRider__WriterDesc_WriteBool)((TextRider__Writer)i0, i1);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3587)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__LongInt(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_INT32 lint) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3695)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3726)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  i1 = lint;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3758)))), TextRider__WriterDesc_WriteLInt)),TextRider__WriterDesc_WriteLInt)((TextRider__Writer)i0, i1, 0);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3791)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__ShortInt(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_INT8 sint) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3902)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3933)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  i1 = sint;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3965)))), TextRider__WriterDesc_WriteSInt)),TextRider__WriterDesc_WriteSInt)((TextRider__Writer)i0, i1, 0);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 3998)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__Int(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_INT16 _int) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4103)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4134)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  i1 = _int;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4166)))), TextRider__WriterDesc_WriteInt)),TextRider__WriterDesc_WriteInt)((TextRider__Writer)i0, i1, 0);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4197)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__Hex(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_INT32 lint) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4298)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4329)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  i1 = lint;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4361)))), TextRider__WriterDesc_WriteHex)),TextRider__WriterDesc_WriteHex)((TextRider__Writer)i0, i1, 8);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4393)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

static void Log__HexAdr(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_INT64 adr) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4498)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4529)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  i1 = adr;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4595)))), TextRider__WriterDesc_WriteHex)),TextRider__WriterDesc_WriteHex)((TextRider__Writer)i0, (_lsh(OOC_INT64, i1, (-32))), 8);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4647)))), TextRider__WriterDesc_WriteHex)),TextRider__WriterDesc_WriteHex)((TextRider__Writer)i0, (_lsh(OOC_INT64, (_lsh(OOC_INT64, i1, 32)), (-32))), 8);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4763)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__LongReal(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_REAL64 lreal) {
  register OOC_INT64 i0;
  register OOC_REAL64 d0;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4875)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4906)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  d0 = lreal;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4938)))), TextRider__WriterDesc_WriteLReal)),TextRider__WriterDesc_WriteLReal)((TextRider__Writer)i0, d0, 24, 17);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 4978)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__Real(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_REAL32 real) {
  register OOC_INT64 i0;
  register OOC_REAL32 f0;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5082)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5113)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  f0 = real;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5145)))), TextRider__WriterDesc_WriteReal)),TextRider__WriterDesc_WriteReal)((TextRider__Writer)i0, f0, 16, 9);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5182)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__LongRealEng(OOC_REAL64 lreal) {
  register OOC_INT64 i0;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5265)))), TextRider__WriterDesc_WriteLRealEng)),TextRider__WriterDesc_WriteLRealEng)((TextRider__Writer)i0, (void*)(OOC_INT64)&lreal, 26, 17);
  return;
  ;
}

void Log__RealEng(OOC_REAL32 real) {
  register OOC_INT64 i0;
  register OOC_REAL32 f0;

  i0 = (OOC_INT64)Log__writer;
  f0 = real;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5368)))), TextRider__WriterDesc_WriteRealEng)),TextRider__WriterDesc_WriteRealEng)((TextRider__Writer)i0, f0, 18, 9);
  return;
  ;
}

void Log__Set(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_UINT32 s) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5487)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5518)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, ": ", 3);
  i0 = (OOC_INT64)Log__writer;
  i1 = s;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5550)))), TextRider__WriterDesc_WriteSet)),TextRider__WriterDesc_WriteSet)((TextRider__Writer)i0, i1);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5576)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__Msg(const OOC_CHAR8 msg[], OOC_LEN msg_0d) {
  register OOC_INT64 i0;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5662)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)msg, msg_0d);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5693)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__Ln(void) {
  register OOC_INT64 i0;

  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 5748)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  return;
  ;
}

void Log__Ptr(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_PTR ptr) {
  register OOC_INT64 i0,i1;

  i0 = (OOC_INT64)ptr;
  i1 = i0==(OOC_INT64)0;
  if (i1) goto l3;
  Log__HexAdr((void*)(OOC_INT64)msg, msg_0d, (_type_cast_fast(OOC_INT64, OOC_INT64, i0)));
  goto l4;
l3:
  Log__String((void*)(OOC_INT64)msg, msg_0d, "NIL", 4);
l4:
  return;
  ;
}

void Log__Adr(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_CHAR8 x[], OOC_LEN x_0d) {

  Log__HexAdr((void*)(OOC_INT64)msg, msg_0d, (OOC_INT64)x);
  return;
  ;
}

void Log__Type(const OOC_CHAR8 msg[], OOC_LEN msg_0d, OOC_PTR ptr) {
  register OOC_INT64 i0,i1;
  RT0__Struct type;
  OOC_CHAR8 str[256];

  i0 = (OOC_INT64)ptr;
  i1 = i0==(OOC_INT64)0;
  if (i1) goto l3;
  i0 = (OOC_INT64)RT0__TypeOf((void*)i0);
  type = (RT0__Struct)i0;
  i1 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i1, 6502)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i1, (void*)(OOC_INT64)msg, msg_0d);
  i1 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i1, 6535)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i1, ": ", 3);
  i1 = (OOC_INT64)*(OOC_INT64*)((_check_pointer(i0, 6573))+16);
  i1 = (OOC_INT64)*(OOC_INT64*)(_check_pointer(i1, 6581));
  _copy_8((const void*)(_check_pointer(i1, 6587)),(void*)(OOC_INT64)str,256);
  i1 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i1, 6608)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i1, (void*)(OOC_INT64)str, 256);
  i1 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i1, 6641)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i1, ".", 2);
  i0 = (OOC_INT64)*(OOC_INT64*)((_check_pointer(i0, 6678))+24);
  _copy_8((const void*)(_check_pointer(i0, 6684)),(void*)(OOC_INT64)str,256);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 6705)))), TextRider__WriterDesc_WriteString)),TextRider__WriterDesc_WriteString)((TextRider__Writer)i0, (void*)(OOC_INT64)str, 256);
  i0 = (OOC_INT64)Log__writer;
  OOC_TBCALL(((OOC_INT64)OOC_TBPROC_ADR(((OOC_INT64)OOC_TYPE_TAG((_check_pointer(i0, 6738)))), TextRider__WriterDesc_WriteLn)),TextRider__WriterDesc_WriteLn)((TextRider__Writer)i0);
  goto l4;
l3:
  Log__String((void*)(OOC_INT64)msg, msg_0d, "NIL", 4);
l4:
  return;
  ;
}

void OOC_Log_init(void) {

  Log__SetWriter((TextRider__Writer)(OOC_INT64)0);
  return;
  ;
}

/* --- */
