Major Features
- Added item level inline macros.
- Support for more complex
match,if letandwhile let- Includes recursive variants, structs, tuples, and numeric values.
- Added
ByteSpanin corelib.
Breaking Changes
- Global impls
- impls defined near the type are always considered when solving an impl - even if the type doesn't exist.
- Made
Iterator::foldbe consuming. #8214 - Made
let x = y;move non-copyy. #8521 - Changed bytearray pending word into
Byte31Index. #8516- Should only affect users that use old edition and accessed the internal fields of ByteArray.
Bug Fixes
- Handling zero-sized generics. #7990
- Properly recognising when a closure is not fully concrete. #7987
- Const-folded
popfrom empty arrays and spans keep the expected var. by @orizi in #8117 - Fix const reported as unused. #8139
- Added dignostics for having a starkware interface with a body. #8216
- Block tail expressions fully process attributes. #8257
- disallow named arguments in closures. #8278
- Not generating expressions of deref if not found. #8295
- added is_zero functions to extern consts list. #8360
- add diagnostic when use star causes cycles. #8463
- Expose
SumandProducttraits. #8542
Other new features
- Add
Nullable::deref_or_else. #8026 - feat(semantic): support allow(unused_variables) by @giladchase in #8289
- added inference for negative impls. #8339
- Implemented
sub_pointersfor Option. #8525 - Added support for override file location using
path. by @orizi in #8557
Optimizations
Compiler runtime
- Less green lookups + string manip - direct usage of file content. #7966
- Made
get_submodulequery based instead of iteration based. #7980 - Removed location fetching when
get_dummy_program_for_size_estimation. #7982 - Refactored Maps from CostTokenType to be defined once. #8021
- Changed CostTokenMap type to vec-map. #8023
- Creating metadata only once. #8019
- Updated salsa version.
Gas usage
- Improved ByteArray iteration.
- Improved ByteArray manipulation.
- Compute ByteArray sha256 via iterator. #8540
Code size
- Added common-expression-elimination optimization. #8217
- Const folding of matching on snapshots. #8377
- Using
unwrap_syscallinstead of simpleunwrapwhere possible. #8561
New Contributors
- @xihuwenhua made their first contribution in #7994
- @GarmashAlex made their first contribution in #8037
- @suobitong made their first contribution in #8040
- @MozirDmitriy made their first contribution in #8055
- @Galoretka made their first contribution in #8074
- @lechpzn made their first contribution in #8098
- @radik878 made their first contribution in #8106
- @Snezhkko made their first contribution in #8120
- @forkfury made their first contribution in #8124
- @Forostovec made their first contribution in #8126
- @fifalodm made their first contribution in #8127
- @Fibonacci747 made their first contribution in #8138
- @kurahin made their first contribution in #8147
- @sashass1315 made their first contribution in #8153
- @Bashmunta made their first contribution in #8155
- @phrwlk made their first contribution in #8148
- @dneptolus made their first contribution in #8161
- @avorylli made their first contribution in #8166
- @oooLowNeoNooo made their first contribution in #8168
- @SADfronov made their first contribution in #8174
- @ANtutov made their first contribution in #8200
- @viktorking7 made their first contribution in #8318
- @keeghcet made their first contribution in #8372
- @Princetimix69 made their first contribution in #8460
- @goldlinker made their first contribution in #8528
- @spuradage made their first contribution in #8536
- @wyrapeseed made their first contribution in #8552
Full Changelog: v2.12.3...v2.13.0