mirror of
https://github.com/Ed94/gencpp.git
synced 2024-12-22 07:44:45 -08:00
More fixes for zpl update...
This commit is contained in:
parent
69e26bbdf8
commit
4c4fe98e7e
@ -70,10 +70,10 @@ sw token_fmt_va( char* buf, uw buf_size, char const* fmt, s32 num_tokens, va_lis
|
|||||||
TokEntry entry
|
TokEntry entry
|
||||||
{
|
{
|
||||||
value,
|
value,
|
||||||
strnlen(value, (sw)128)
|
str_len(value, (sw)128)
|
||||||
};
|
};
|
||||||
|
|
||||||
u32 key = crc32( token, strnlen(token, 32) );
|
u32 key = crc32( token, str_len(token, 32) );
|
||||||
|
|
||||||
tokmap_set( & tok_map, key, entry );
|
tokmap_set( & tok_map, key, entry );
|
||||||
}
|
}
|
||||||
|
@ -2429,11 +2429,11 @@ namespace gen
|
|||||||
return Code::Invalid;
|
return Code::Invalid;
|
||||||
}
|
}
|
||||||
|
|
||||||
char const* name = bprintf( "operator%s", to_str(op) );
|
char const* name = str_fmt_buf( "operator%s", to_str(op) );
|
||||||
|
|
||||||
Code
|
Code
|
||||||
result = make_code();
|
result = make_code();
|
||||||
result->Name = get_cached_string( name, strnlen(name, MaxNameLength) );
|
result->Name = get_cached_string( name, str_len(name, MaxNameLength) );
|
||||||
|
|
||||||
if (params_code)
|
if (params_code)
|
||||||
result->add_entry( params_code );
|
result->add_entry( params_code );
|
||||||
@ -3177,7 +3177,7 @@ namespace gen
|
|||||||
|
|
||||||
if ( body.Length )
|
if ( body.Length )
|
||||||
{
|
{
|
||||||
memcopy( entries_code, body.Text, body.Length );
|
mem_copy( entries_code, body.Text, body.Length );
|
||||||
|
|
||||||
Code untyped_body = untyped_str( entries_length, entries_code );
|
Code untyped_body = untyped_str( entries_length, entries_code );
|
||||||
|
|
||||||
@ -3714,7 +3714,7 @@ namespace gen
|
|||||||
|
|
||||||
va_list va;
|
va_list va;
|
||||||
va_start(va, fmt);
|
va_start(va, fmt);
|
||||||
sw length = snprintf_va(buf, ZPL_PRINTF_MAXLEN, fmt, va);
|
sw length = str_fmt_va(buf, ZPL_PRINTF_MAXLEN, fmt, va);
|
||||||
va_end(va);
|
va_end(va);
|
||||||
|
|
||||||
Code
|
Code
|
||||||
@ -3739,7 +3739,7 @@ namespace gen
|
|||||||
|
|
||||||
Code
|
Code
|
||||||
result = make_code();
|
result = make_code();
|
||||||
result->Name = get_cached_string( fmt, strnlen(fmt, MaxNameLength) );
|
result->Name = get_cached_string( fmt, str_len(fmt, MaxNameLength) );
|
||||||
result->Type = ECode::Untyped;
|
result->Type = ECode::Untyped;
|
||||||
result->Content = get_cached_string( buf, length );
|
result->Content = get_cached_string( buf, length );
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user