async_sinh
Translation status: Tiếng Việt reader-locale proof. Term names and code fences follow the vi pack; supporting prose may still be English.
Callable posture for asynchronous stream functions.
Aliases: async_generator
Syntax: hàm name(…) async_sinh → T
Category#
async
Related#
Examples#
radix/corpus/fient/fient.fab (canonical · keyword)#
Callable posture for asynchronous stream functions.
# =============================================================================
# async_sinh — Asynchronous stream callable posture
# =============================================================================
#
# What this teaches:
# • Async stream posture: `async_sinh → T` yields promised pulls of `T`.
# • Yield with `nhường`; consume the stream with `lặp từ` inside an async body.
#
# Common mistakes:
# • Expecting every backend to lower `async_sinh` — some fail closed until a
# channel/async-cursor carrier lands.
#
# See also: sinh, async, nhường
# =============================================================================
# GRAMMAR:
# callablePosture :← 'async_sinh'
#
# BACKEND:
# Product path is Rust async-cursor; other backends may fail closed.
hàm stream() async_sinh → số {
nhường 1
nhường 2
}
bắt_đầu_bất_đồng_bộ {
lặp từ stream() hằng n {
ghi_chú n
}
}Expected output:
1
2