The code you suggested gives a compiler error.
But the pointer definitely points to something. The code starts off and runs fine at the start. The correct value is displayed for a while. However, after some time, the value suddenly changes. I am not sure if the Arduino itself is moving memory locations or if passing a pointer into a function asking for an array is causing something to go crazy. Here is the function I am passing the pointer into:
void CubeControl::writeLayer(byte layer[], byte col, unsigned int duration)
{
//Set reset pin to high, to allow writing. Low is active reset in shift registers.
for (int chips = 0; chips < numRegisters; chips++)
{
digitalWrite(registerResetPin[chips], HIGH);
}
//Turn layer pin to LOW to allow current flow
digitalWrite(layerPin[col], LOW);
for (int chips = 0; chips < numRegisters; chips++)
{
shiftOut(registerDataPin[chips], registerClockPin[chips], LSBFIRST, layer[chips]);
}
//Delay the output so that you can actually see the output.
delay(duration);
//Reset the shift registers. Helps avoid bad data.
for (int chips = 0; chips < numRegisters; chips++)
{
digitalWrite(registerResetPin[chips], LOW);
}
//Turns off the layer.
digitalWrite(layerPin[col], HIGH);
return;
}