3 ms·
Whats the status of std.stream?
by jeremiep 11y ago
Whats the status of std.stream?
- bionsuba 11y agoNot AA, but streams have been pretty much deprecated in favor of ranges.
- jeremiep 11y agoAren't ranges and streams conceptually different? Ranges are for data traversals and streams are for data transfers. I want more than empty, front and popFront to manipulate byte buffers with high performance. I'm thinking about reading data structures, performing bit conversion, and extracting primitive values from untyped byte arrays. Going as far as to reuse the array's memory for the values being read which isn't possible with ranges.
- andralex 11y agoI think the lack of demand for it has been an indicator that ranges with additions are just enough. We're currently looking at adding optional primitives to ranges in a Design by Introspection manner to support bulk streaming of data.
- jeremiep 11y agoI would definitely love to see range primitives support bulk streaming! How about adding a byte buffer concept alongside with ranges? I'm thinking an API similar to Netty's ByteBuf but using D's compile-time capabilities instead. These would be valid ranges as well but offer direct byte access on top.
- jeremiep 11y agoAlso, while on the subject of status updates, what's the status of std.reflection? Any chance UDAs could be included in there? :) It would be great if the reflection info could be outputted to a separate file for those cases where its only needed during program initialization or used by external tools.