Remove usage of VLA's as they aren't supported by C++.
Merge pull request #6 from robertmaynard/remove_vla_usage

Remove usage of VLA's as they aren't supported by C++.