简体中文
Telegram
JJavaScript/Node.js 台灣

JavaScript/Node.js 台灣

@JavaScriptTw · 群组 · 科技 · 收录于 2026-07-05
1 999成员
630 天内发言的人
1130 天内的消息
103 350索引中的消息
H
我就是挑战下用Zig写一个业务逻辑🥹 导致我现在效率低下
H
User said: Zig中 arrayhashmap 如果我替换一个Key的值 之后,原来的值会自动被内存回收吗 ChatGPT said: 在 Zig 中,如果你使用的是 std.AutoHashMap 或 std.ArrayHashMap 并替换了某个 key 对应的值: 🔥 Zig 并不会自动回收原来的值所使用的内存,除非你手动释放! 我每用一个函数都要问问GPT内存问题, 😂
  1. 🍳
    const std = @import("std"); const allocator = std.heap.c_allocator; pub fn main() !void { // 省略 // The put() function returns the old entry const old_entry = try map.put(key, value2); std.debug.print("Replaced with value: {d}\n", .{value2.*}); // 3. Manually free the old value if (old_entry) |entry| { std.debug.print("Old value was: {d}\n", .{entry.value.*}); allocator.destroy(entry.value); // You MUST do this! } }
整个讨论串 · 4 条回复 →
A
我用 rust 写业务逻辑,感觉熟练后非常爽
整个讨论串 · 1 条回复 →
整个讨论串 · 1 条回复 →
♡
ArkTS对TypeScript的动态类型特性施加了更严格的限制,以减少运行时开销,提高执行效率。通过取消动态类型特性,ArkTS代码能更有效地被运行前编译和优化,从而实现更快的应用启动和更低的功耗。
  1. R
    起手式 new function/eval 的库都是智障。。。
整个讨论串 · 1 条回复 →
R
到处受限,browser extension/worker 都不让用
V
贴纸
sticker.webp · 12 KB · 点击显示
🤡

来自搜索索引的公开信息流 ChatCrawler ——“公开 Telegram 的 Google”;随着该社群被抓取而更新。 时间为 UTC。

仅限公开内容,使用 Telegram 官方 API。 关于 · 常见问题 · 索引限制 · 移除页面 · 目录 · 搜索 · 计算方法