I can see that when the for loop closes then it has assigned index to 100 and that is out of bounds of the array, even though its never used.
Perhaps a warning that you migh be doing something bad, but why a compiler error ?
- uint8_t databuff[100];
- void loop()
- {
- }
- void setup()
- {
- uint8_t index, ptr;
- //fill data buffer with 0 to 99
- for (index = 0; index <= 99; index++);
- {
- ptr = index;
- databuff[ptr] = ptr;
- }
- }