🐎 ci(stage upgrade): split to 4 stage
This commit is contained in:
40
deps/toml/toml.cpp
vendored
40
deps/toml/toml.cpp
vendored
@@ -2502,32 +2502,32 @@ int toml_rtos(toml_raw_t src, char **ret)
|
||||
|
||||
toml_datum_t toml_string_at(const toml_array_t *arr, int idx)
|
||||
{
|
||||
toml_datum_t ret;
|
||||
memset(&ret, 0, sizeof(ret));
|
||||
toml_datum_t ret={};
|
||||
//memset(&ret, 0, sizeof(ret));
|
||||
ret.ok = (0 == toml_rtos(toml_raw_at(arr, idx), &ret.u.s));
|
||||
return ret;
|
||||
}
|
||||
|
||||
toml_datum_t toml_bool_at(const toml_array_t *arr, int idx)
|
||||
{
|
||||
toml_datum_t ret;
|
||||
memset(&ret, 0, sizeof(ret));
|
||||
toml_datum_t ret={};
|
||||
//memset(&ret, 0, sizeof(ret));
|
||||
ret.ok = (0 == toml_rtob(toml_raw_at(arr, idx), &ret.u.b));
|
||||
return ret;
|
||||
}
|
||||
|
||||
toml_datum_t toml_int_at(const toml_array_t *arr, int idx)
|
||||
{
|
||||
toml_datum_t ret;
|
||||
memset(&ret, 0, sizeof(ret));
|
||||
toml_datum_t ret={};
|
||||
//memset(&ret, 0, sizeof(ret));
|
||||
ret.ok = (0 == toml_rtoi(toml_raw_at(arr, idx), &ret.u.i));
|
||||
return ret;
|
||||
}
|
||||
|
||||
toml_datum_t toml_double_at(const toml_array_t *arr, int idx)
|
||||
{
|
||||
toml_datum_t ret;
|
||||
memset(&ret, 0, sizeof(ret));
|
||||
toml_datum_t ret={};
|
||||
//memset(&ret, 0, sizeof(ret));
|
||||
ret.ok = (0 == toml_rtod(toml_raw_at(arr, idx), &ret.u.d));
|
||||
return ret;
|
||||
}
|
||||
@@ -2535,8 +2535,8 @@ toml_datum_t toml_double_at(const toml_array_t *arr, int idx)
|
||||
toml_datum_t toml_timestamp_at(const toml_array_t *arr, int idx)
|
||||
{
|
||||
toml_timestamp_t ts;
|
||||
toml_datum_t ret;
|
||||
memset(&ret, 0, sizeof(ret));
|
||||
toml_datum_t ret={};
|
||||
//memset(&ret, 0, sizeof(ret));
|
||||
ret.ok = (0 == toml_rtots(toml_raw_at(arr, idx), &ts));
|
||||
if (ret.ok)
|
||||
{
|
||||
@@ -2567,8 +2567,8 @@ toml_datum_t toml_timestamp_at(const toml_array_t *arr, int idx)
|
||||
|
||||
toml_datum_t toml_string_in(const toml_table_t *arr, const char *key)
|
||||
{
|
||||
toml_datum_t ret;
|
||||
memset(&ret, 0, sizeof(ret));
|
||||
toml_datum_t ret={};
|
||||
//memset(&ret, 0, sizeof(ret));
|
||||
toml_raw_t raw = toml_raw_in(arr, key);
|
||||
if (raw)
|
||||
{
|
||||
@@ -2579,24 +2579,24 @@ toml_datum_t toml_string_in(const toml_table_t *arr, const char *key)
|
||||
|
||||
toml_datum_t toml_bool_in(const toml_table_t *arr, const char *key)
|
||||
{
|
||||
toml_datum_t ret;
|
||||
memset(&ret, 0, sizeof(ret));
|
||||
toml_datum_t ret={};
|
||||
//memset(&ret, 0, sizeof(ret));
|
||||
ret.ok = (0 == toml_rtob(toml_raw_in(arr, key), &ret.u.b));
|
||||
return ret;
|
||||
}
|
||||
|
||||
toml_datum_t toml_int_in(const toml_table_t *arr, const char *key)
|
||||
{
|
||||
toml_datum_t ret;
|
||||
memset(&ret, 0, sizeof(ret));
|
||||
toml_datum_t ret={};
|
||||
//memset(&ret, 0, sizeof(ret));
|
||||
ret.ok = (0 == toml_rtoi(toml_raw_in(arr, key), &ret.u.i));
|
||||
return ret;
|
||||
}
|
||||
|
||||
toml_datum_t toml_double_in(const toml_table_t *arr, const char *key)
|
||||
{
|
||||
toml_datum_t ret;
|
||||
memset(&ret, 0, sizeof(ret));
|
||||
toml_datum_t ret={};
|
||||
//memset(&ret, 0, sizeof(ret));
|
||||
ret.ok = (0 == toml_rtod(toml_raw_in(arr, key), &ret.u.d));
|
||||
return ret;
|
||||
}
|
||||
@@ -2604,8 +2604,8 @@ toml_datum_t toml_double_in(const toml_table_t *arr, const char *key)
|
||||
toml_datum_t toml_timestamp_in(const toml_table_t *arr, const char *key)
|
||||
{
|
||||
toml_timestamp_t ts;
|
||||
toml_datum_t ret;
|
||||
memset(&ret, 0, sizeof(ret));
|
||||
toml_datum_t ret={};
|
||||
//memset(&ret, 0, sizeof(ret));
|
||||
ret.ok = (0 == toml_rtots(toml_raw_in(arr, key), &ts));
|
||||
if (ret.ok)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user