Update reference-types.rst

Clarify comment using language similar to that in the Array section of the documentation. Previously it said simply "Because of that..." but what the word "that" was about, was not evident.
This commit is contained in:
aathan 2022-03-23 09:07:34 -07:00 committed by Leo Alt
parent e27cb025c2
commit f1a5bc7ed9

View File

@ -379,8 +379,10 @@ Array Members
uint[2**20] aLotOfIntegers; uint[2**20] aLotOfIntegers;
// Note that the following is not a pair of dynamic arrays but a // Note that the following is not a pair of dynamic arrays but a
// dynamic array of pairs (i.e. of fixed size arrays of length two). // dynamic array of pairs (i.e. of fixed size arrays of length two).
// Because of that, T[] is always a dynamic array of T, even if T // In Solidity, T[k] and T[] are always arrays with elements of type T,
// itself is an array. // even if T itself is an array.
// Because of that, bool[2][] is a dynamic array of elements
// that are bool[2]. This is different from other languages, like C.
// Data location for all state variables is storage. // Data location for all state variables is storage.
bool[2][] pairsOfFlags; bool[2][] pairsOfFlags;