When range overlap happens, the last one takes higher priority.\r
When the function returns, either all the attributes are set successfully,\r
or none of them is set.\r
When range overlap happens, the last one takes higher priority.\r
When the function returns, either all the attributes are set successfully,\r
or none of them is set.\r