chapel-lang/chapel — pull request #1023 by benharsh (2014-12-17 22:21:37+00:00)
Title: Prevent removal of initialization for runtime types

This patch fixes a bug where a reduction on an array of runtime types would result in a runtime segfault. This segfault occurred because a runtime type variable was not initialized properly.

The new test is small example of such a case, where the reduction needs runtime type information about the associative domain of integers.

The compiler would add a call to initialize this variable, but the parent block would later be removed. This patch to the compiler modifies such a block so that it won't be removed.

- [x] Single node testing
- [x] Gasnet testing