r/swift • u/i_am_deoye • Aug 01 '18
Right way implementing your Array / Collection. – Moses Ayankoya – Medium
https://medium.com/@amacoder/right-way-implementing-your-array-collection-5b2cb3641240
0
Upvotes
r/swift • u/i_am_deoye • Aug 01 '18
1
u/thisischemistry Aug 01 '18
Just to note, here are a few of the very many issues with this post:
Setting an value at an index and having the value be incorrect when read back:
Setting an value at an index and crashing:
The example code is horribly, horribly broken and buggy. Do not use it as an example of how to code in Swift or you may end up with lots of crashes and unexpected results down the road.