// File: /workspace/github_c_makefile_star2_O0/johsteffens[P]beth/xoico/src/xoico.xo.c
// Function: xoico_stamp_create_structured_multiline_string
st_s* xoico_stamp_create_structured_multiline_string( const sc_t s, sz_t indent )
{
    // xoico_stamp.x:227:1
    
    st_s* out = st_s_create();
    sz_t ind = indent;
    bl_t newline = true;
    for(sz_t i = 0; s[ i ] != 0; i++ )
    {
        char c = s[ i ];
        if( c == ';' )
        {
            if( newline ) st_s_push_fa(out,"#rn{ }\"", ind );
            st_s_push_char(out,c );
            st_s_push_fa(out,"\"\n" );
            newline = true;
        }
        else if( c == '{' )
        {
            if( newline )
            {
                st_s_push_fa(out,"#rn{ }\"{\"", ind );
            }
            else
            {
                st_s_push_fa(out,"\"\n#rn{ }\"{\"", ind );
            }
            if( s[ i + 1 ] != 0 ) st_s_push_char(out,'\n' );
            ind += 4;
            newline = true;
    
        }
        else if( c == '}' )
        {
            ind -= 4;
            if( newline )
            {
                st_s_push_fa(out,"#rn{ }\"}\"", ind );
            }
            else
            {
                st_s_push_fa(out,"\"\n#rn{ }\"}\"", ind );
            }
            if( s[ i + 1 ] != 0 ) st_s_push_char(out,'\n' );
            newline = true;
        }
        else if( c == ' ' )
        {
            if( !newline )
            {
                if( s[ i + 1 ] != ';' && s[ i + 1 ] != '{' && s[ i + 1 ] != '}' && s[ i + 1 ] != 0 )
                {
                    st_s_push_char(out,c );
                }
            }
        }
        else
        {
            if( newline )
            {
                st_s_push_fa(out,"#rn{ }\"", ind );
                newline = false;
            }
            st_s_push_char(out,c );
        }
    }
    
    if( !newline ) st_s_push_char(out,'"' );
    return  out;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movb $0x0, %al
callq 0xff2e0
movq %rax, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
movb $0x1, -0x21(%rbp)
movq $0x0, -0x30(%rbp)
movq -0x8(%rbp), %rax
movq -0x30(%rbp), %rcx
movsbl (%rax,%rcx), %eax
cmpl $0x0, %eax
je 0x1ba01
movq -0x8(%rbp), %rax
movq -0x30(%rbp), %rcx
movb (%rax,%rcx), %al
movb %al, -0x31(%rbp)
movsbl -0x31(%rbp), %eax
cmpl $0x3b, %eax
jne 0x1b86f
testb $0x1, -0x21(%rbp)
je 0x1b847
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rdx
leaq 0x119c9e(%rip), %rsi    # 0x1354de
movb $0x0, %al
callq 0x100210
movq -0x18(%rbp), %rdi
movsbl -0x31(%rbp), %esi
callq 0xffba0
movq -0x18(%rbp), %rdi
leaq 0x11917a(%rip), %rsi    # 0x1349d9
movb $0x0, %al
callq 0x100210
movb $0x1, -0x21(%rbp)
jmp 0x1b9ee
movsbl -0x31(%rbp), %eax
cmpl $0x7b, %eax
jne 0x1b8e1
testb $0x1, -0x21(%rbp)
je 0x1b896
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rdx
leaq 0x119c5b(%rip), %rsi    # 0x1354e8
movb $0x0, %al
callq 0x100210
jmp 0x1b8ac
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rdx
leaq 0x119c41(%rip), %rsi    # 0x1354e6
movb $0x0, %al
callq 0x100210
movq -0x8(%rbp), %rax
movq -0x30(%rbp), %rcx
movsbl 0x1(%rax,%rcx), %eax
cmpl $0x0, %eax
je 0x1b8cc
movq -0x18(%rbp), %rdi
movl $0xa, %esi
callq 0xffba0
movq -0x20(%rbp), %rax
addq $0x4, %rax
movq %rax, -0x20(%rbp)
movb $0x1, -0x21(%rbp)
jmp 0x1b9ec
movsbl -0x31(%rbp), %eax
cmpl $0x7d, %eax
jne 0x1b953
movq -0x20(%rbp), %rax
subq $0x4, %rax
movq %rax, -0x20(%rbp)
testb $0x1, -0x21(%rbp)
je 0x1b914
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rdx
leaq 0x119be9(%rip), %rsi    # 0x1354f4
movb $0x0, %al
callq 0x100210
jmp 0x1b92a
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rdx
leaq 0x119bcf(%rip), %rsi    # 0x1354f2
movb $0x0, %al
callq 0x100210
movq -0x8(%rbp), %rax
movq -0x30(%rbp), %rcx
movsbl 0x1(%rax,%rcx), %eax
cmpl $0x0, %eax
je 0x1b94a
movq -0x18(%rbp), %rdi
movl $0xa, %esi
callq 0xffba0
movb $0x1, -0x21(%rbp)
jmp 0x1b9ea
movsbl -0x31(%rbp), %eax
cmpl $0x20, %eax
jne 0x1b9bb
testb $0x1, -0x21(%rbp)
jne 0x1b9b9
movq -0x8(%rbp), %rax
movq -0x30(%rbp), %rcx
movsbl 0x1(%rax,%rcx), %eax
cmpl $0x3b, %eax
je 0x1b9b7
movq -0x8(%rbp), %rax
movq -0x30(%rbp), %rcx
movsbl 0x1(%rax,%rcx), %eax
cmpl $0x7b, %eax
je 0x1b9b7
movq -0x8(%rbp), %rax
movq -0x30(%rbp), %rcx
movsbl 0x1(%rax,%rcx), %eax
cmpl $0x7d, %eax
je 0x1b9b7
movq -0x8(%rbp), %rax
movq -0x30(%rbp), %rcx
movsbl 0x1(%rax,%rcx), %eax
cmpl $0x0, %eax
je 0x1b9b7
movq -0x18(%rbp), %rdi
movsbl -0x31(%rbp), %esi
callq 0xffba0
jmp 0x1b9b9
jmp 0x1b9e8
testb $0x1, -0x21(%rbp)
je 0x1b9db
movq -0x18(%rbp), %rdi
movq -0x20(%rbp), %rdx
leaq 0x119b0e(%rip), %rsi    # 0x1354de
movb $0x0, %al
callq 0x100210
movb $0x0, -0x21(%rbp)
movq -0x18(%rbp), %rdi
movsbl -0x31(%rbp), %esi
callq 0xffba0
jmp 0x1b9ea
jmp 0x1b9ec
jmp 0x1b9ee
jmp 0x1b9f0
movq -0x30(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x30(%rbp)
jmp 0x1b7ff
testb $0x1, -0x21(%rbp)
jne 0x1ba15
movq -0x18(%rbp), %rdi
movl $0x22, %esi
callq 0xffba0
movq -0x18(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nop