@@ -15,8 +15,8 @@ namespace tl {
1515// ===== JOB WORKERS =====
1616
1717bool K2InvokeJobWorker::fetch (tl::TLBuffer& tlb) noexcept {
18- tl::details:: magic magic{};
19- tl::details:: mask flags{};
18+ tl::magic magic{};
19+ tl::mask flags{};
2020 bool ok{magic.fetch (tlb) && magic.expect (K2_INVOKE_JOB_WORKER_MAGIC )};
2121 ok &= flags.fetch (tlb);
2222 ok &= image_id.fetch (tlb);
@@ -28,8 +28,8 @@ bool K2InvokeJobWorker::fetch(tl::TLBuffer& tlb) noexcept {
2828}
2929
3030void K2InvokeJobWorker::store (tl::TLBuffer& tlb) const noexcept {
31- tl::details:: magic{.value = K2_INVOKE_JOB_WORKER_MAGIC }.store (tlb);
32- tl::details:: mask{.value = ignore_answer ? IGNORE_ANSWER_FLAG : 0x0 }.store (tlb);
31+ tl::magic{.value = K2_INVOKE_JOB_WORKER_MAGIC }.store (tlb);
32+ tl::mask{.value = ignore_answer ? IGNORE_ANSWER_FLAG : 0x0 }.store (tlb);
3333 image_id.store (tlb);
3434 job_id.store (tlb);
3535 timeout_ns.store (tlb);
@@ -39,33 +39,33 @@ void K2InvokeJobWorker::store(tl::TLBuffer& tlb) const noexcept {
3939// ===== CRYPTO =====
4040
4141void GetCryptosecurePseudorandomBytes::store (tl::TLBuffer& tlb) const noexcept {
42- tl::details:: magic{.value = GET_CRYPTOSECURE_PSEUDORANDOM_BYTES_MAGIC }.store (tlb);
42+ tl::magic{.value = GET_CRYPTOSECURE_PSEUDORANDOM_BYTES_MAGIC }.store (tlb);
4343 size.store (tlb);
4444}
4545
4646void GetPemCertInfo::store (tl::TLBuffer& tlb) const noexcept {
47- tl::details:: magic{.value = GET_PEM_CERT_INFO_MAGIC }.store (tlb);
47+ tl::magic{.value = GET_PEM_CERT_INFO_MAGIC }.store (tlb);
4848 tl::Bool{.value = is_short}.store (tlb);
4949 bytes.store (tlb);
5050}
5151
5252void DigestSign::store (tl::TLBuffer& tlb) const noexcept {
53- tl::details:: magic{.value = DIGEST_SIGN_MAGIC }.store (tlb);
53+ tl::magic{.value = DIGEST_SIGN_MAGIC }.store (tlb);
5454 data.store (tlb);
5555 private_key.store (tlb);
5656 tlb.store_trivial <uint32_t >(algorithm);
5757}
5858
5959void DigestVerify::store (tl::TLBuffer& tlb) const noexcept {
60- tl::details:: magic{.value = DIGEST_VERIFY_MAGIC }.store (tlb);
60+ tl::magic{.value = DIGEST_VERIFY_MAGIC }.store (tlb);
6161 data.store (tlb);
6262 public_key.store (tlb);
6363 tlb.store_trivial <uint32_t >(algorithm);
6464 signature.store (tlb);
6565}
6666
6767void CbcDecrypt::store (tl::TLBuffer& tlb) const noexcept {
68- tl::details:: magic{.value = CBC_DECRYPT_MAGIC }.store (tlb);
68+ tl::magic{.value = CBC_DECRYPT_MAGIC }.store (tlb);
6969 tlb.store_trivial <uint32_t >(algorithm);
7070 tlb.store_trivial <uint32_t >(padding);
7171 passphrase.store (tlb);
@@ -74,7 +74,7 @@ void CbcDecrypt::store(tl::TLBuffer& tlb) const noexcept {
7474}
7575
7676void CbcEncrypt::store (tl::TLBuffer& tlb) const noexcept {
77- tl::details:: magic{.value = CBC_ENCRYPT_MAGIC }.store (tlb);
77+ tl::magic{.value = CBC_ENCRYPT_MAGIC }.store (tlb);
7878 tlb.store_trivial <uint32_t >(algorithm);
7979 tlb.store_trivial <uint32_t >(padding);
8080 passphrase.store (tlb);
@@ -83,13 +83,13 @@ void CbcEncrypt::store(tl::TLBuffer& tlb) const noexcept {
8383}
8484
8585void Hash::store (tl::TLBuffer& tlb) const noexcept {
86- tl::details:: magic{.value = HASH_MAGIC }.store (tlb);
86+ tl::magic{.value = HASH_MAGIC }.store (tlb);
8787 tlb.store_trivial <uint32_t >(algorithm);
8888 data.store (tlb);
8989}
9090
9191void HashHmac::store (tl::TLBuffer& tlb) const noexcept {
92- tl::details:: magic{.value = HASH_HMAC_MAGIC }.store (tlb);
92+ tl::magic{.value = HASH_HMAC_MAGIC }.store (tlb);
9393 tlb.store_trivial <uint32_t >(algorithm);
9494 data.store (tlb);
9595 secret_key.store (tlb);
@@ -98,20 +98,20 @@ void HashHmac::store(tl::TLBuffer& tlb) const noexcept {
9898// ===== CONFDATA =====
9999
100100void ConfdataGet::store (tl::TLBuffer& tlb) const noexcept {
101- tl::details:: magic{.value = CONFDATA_GET_MAGIC }.store (tlb);
101+ tl::magic{.value = CONFDATA_GET_MAGIC }.store (tlb);
102102 key.store (tlb);
103103}
104104
105105void ConfdataGetWildcard::store (tl::TLBuffer& tlb) const noexcept {
106- tl::details:: magic{.value = CONFDATA_GET_WILDCARD_MAGIC }.store (tlb);
106+ tl::magic{.value = CONFDATA_GET_WILDCARD_MAGIC }.store (tlb);
107107 wildcard.store (tlb);
108108}
109109
110110// ===== HTTP =====
111111
112112bool K2InvokeHttp::fetch (tl::TLBuffer& tlb) noexcept {
113- tl::details:: magic magic{};
114- tl::details:: mask flags{};
113+ tl::magic magic{};
114+ tl::mask flags{};
115115 bool ok{magic.fetch (tlb) && magic.expect (K2_INVOKE_HTTP_MAGIC )};
116116 ok &= flags.fetch (tlb);
117117 ok &= connection.fetch (tlb);
0 commit comments