Yes, it should be an error.
It will also be an error to set an index more than 100 past the end of the array.
For more information, see the wiki Searching the Forum for Answers section.