[Discuss] Is it common sense to set vec![0u8; 8]
as the default value of Hex
?
#1388
Labels
t:bug
Something isn't working
vec![0u8; 8]
as the default value of Hex
?
#1388
What happened
Is it common sense to set
vec![0u8; 8]
as the default value ofHex
?axon/protocol/src/types/primitive.rs
Lines 111 to 115 in 2877191
In other words, let's pick 5 non-Axon developers randomly and ask them what is the default value of a hex string they think.
I don't think 8 zero bytes was the answer of most people.
An uncommon sense default value is very dangerous.
When we use an open-source type, have we checked their default values carefully before use?
Image that, we import an open-source
U256
, that it has set1
as default value, what will happen.The text was updated successfully, but these errors were encountered: