| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
Complete Plan 051: Auto Flow iterator system (Phases 5-8) Implement iterator and functional programming system with lazy evaluation and eager collection via bang operator. Phase 5 - Bang Operator: - Add postfix ! operator for eager collection - Parser transforms expr! to expr.collect() - Add PREC_POSTFIX constant (precedence level 17) - Implement collect() for ListIter Phase 6 - Extended Adapters: - limit(n) - limit to first n elements (renamed from take) - skip(n) - skip first n elements - enumerate() - add indices to elements - zip(iter) - combine two iterators - chain(iter) - concatenate iterators Phase 7 - Predicate Operators: - any(predicate) - check if any element satisfies predicate - all(predicate) - check if all elements satisfy predicate - find(predicate) - find first matching element - All with short-circuit evaluation Phase 8 - Collect & To Operators: - Enhanced collect() with spec integration - Add Collect<T> spec for polymorphic collection - Comprehensive testing for all collect scenarios Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> | 9 个月前 | |
Complete Plan 051: Auto Flow iterator system (Phases 5-8) Implement iterator and functional programming system with lazy evaluation and eager collection via bang operator. Phase 5 - Bang Operator: - Add postfix ! operator for eager collection - Parser transforms expr! to expr.collect() - Add PREC_POSTFIX constant (precedence level 17) - Implement collect() for ListIter Phase 6 - Extended Adapters: - limit(n) - limit to first n elements (renamed from take) - skip(n) - skip first n elements - enumerate() - add indices to elements - zip(iter) - combine two iterators - chain(iter) - concatenate iterators Phase 7 - Predicate Operators: - any(predicate) - check if any element satisfies predicate - all(predicate) - check if all elements satisfy predicate - find(predicate) - find first matching element - All with short-circuit evaluation Phase 8 - Collect & To Operators: - Enhanced collect() with spec integration - Add Collect<T> spec for polymorphic collection - Comprehensive testing for all collect scenarios Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> | 9 个月前 | |
feat(iter): Implement Plan 051 Phase 2 - Map & Filter adapters Implement iterator adapters for functional programming using generic type fields (enabled by Plan 059 Phase 1). **Changes:** - Update spec.at to use simpler approach (no associated types) - Implement MapIter<I, T, U> with generic type field support - Implement FilterIter<I, T> with generic type field support - Add MapIter and FilterIter to prelude **Simplification Decision:** - Use fn iter() Iter<T> instead of fn iter() .IterT - No associated types needed for current use cases - Cleaner syntax that works with Plan 059's generic type fields **Test Results:** - ✅ test_099_iter_specs - passes - ✅ test_100_map_adapter - passes (generic type field verification) - ✅ test_101_list_iter - passes **Example Usage:** auto // Map adapter transforms elements type MapIter<I, T, U> { iter I // Generic type field - now works! } // Filter adapter filters elements type FilterIter<I, T> { iter I pred fn(T)bool } Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> | 9 个月前 | |
Complete Plan 051: Auto Flow iterator system (Phases 5-8) Implement iterator and functional programming system with lazy evaluation and eager collection via bang operator. Phase 5 - Bang Operator: - Add postfix ! operator for eager collection - Parser transforms expr! to expr.collect() - Add PREC_POSTFIX constant (precedence level 17) - Implement collect() for ListIter Phase 6 - Extended Adapters: - limit(n) - limit to first n elements (renamed from take) - skip(n) - skip first n elements - enumerate() - add indices to elements - zip(iter) - combine two iterators - chain(iter) - concatenate iterators Phase 7 - Predicate Operators: - any(predicate) - check if any element satisfies predicate - all(predicate) - check if all elements satisfy predicate - find(predicate) - find first matching element - All with short-circuit evaluation Phase 8 - Collect & To Operators: - Enhanced collect() with spec integration - Add Collect<T> spec for polymorphic collection - Comprehensive testing for all collect scenarios Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> | 9 个月前 | |
feat(iter): Implement Plan 051 Phase 2 - Map & Filter adapters Implement iterator adapters for functional programming using generic type fields (enabled by Plan 059 Phase 1). **Changes:** - Update spec.at to use simpler approach (no associated types) - Implement MapIter<I, T, U> with generic type field support - Implement FilterIter<I, T> with generic type field support - Add MapIter and FilterIter to prelude **Simplification Decision:** - Use fn iter() Iter<T> instead of fn iter() .IterT - No associated types needed for current use cases - Cleaner syntax that works with Plan 059's generic type fields **Test Results:** - ✅ test_099_iter_specs - passes - ✅ test_100_map_adapter - passes (generic type field verification) - ✅ test_101_list_iter - passes **Example Usage:** auto // Map adapter transforms elements type MapIter<I, T, U> { iter I // Generic type field - now works! } // Filter adapter filters elements type FilterIter<I, T> { iter I pred fn(T)bool } Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> | 9 个月前 | |
Complete Plan 051: Auto Flow iterator system (Phases 5-8) Implement iterator and functional programming system with lazy evaluation and eager collection via bang operator. Phase 5 - Bang Operator: - Add postfix ! operator for eager collection - Parser transforms expr! to expr.collect() - Add PREC_POSTFIX constant (precedence level 17) - Implement collect() for ListIter Phase 6 - Extended Adapters: - limit(n) - limit to first n elements (renamed from take) - skip(n) - skip first n elements - enumerate() - add indices to elements - zip(iter) - combine two iterators - chain(iter) - concatenate iterators Phase 7 - Predicate Operators: - any(predicate) - check if any element satisfies predicate - all(predicate) - check if all elements satisfy predicate - find(predicate) - find first matching element - All with short-circuit evaluation Phase 8 - Collect & To Operators: - Enhanced collect() with spec integration - Add Collect<T> spec for polymorphic collection - Comprehensive testing for all collect scenarios Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> | 9 个月前 | |
Complete Plan 051: Auto Flow iterator system (Phases 5-8) Implement iterator and functional programming system with lazy evaluation and eager collection via bang operator. Phase 5 - Bang Operator: - Add postfix ! operator for eager collection - Parser transforms expr! to expr.collect() - Add PREC_POSTFIX constant (precedence level 17) - Implement collect() for ListIter Phase 6 - Extended Adapters: - limit(n) - limit to first n elements (renamed from take) - skip(n) - skip first n elements - enumerate() - add indices to elements - zip(iter) - combine two iterators - chain(iter) - concatenate iterators Phase 7 - Predicate Operators: - any(predicate) - check if any element satisfies predicate - all(predicate) - check if all elements satisfy predicate - find(predicate) - find first matching element - All with short-circuit evaluation Phase 8 - Collect & To Operators: - Enhanced collect() with spec integration - Add Collect<T> spec for polymorphic collection - Comprehensive testing for all collect scenarios Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com> | 9 个月前 |