chapel-lang/chapel — pull request #986 by vasslitvinov (2014-12-09 03:00:23+00:00)
Title: Removed checks and assertions used with form_Map().

The files createTaskFunctions.cpp and implementForallIntents.cpp
contained these idioms:

form_Map(SymbolMapElem, e, ...) {
INT_ASSERT(e->key);
...

and/or

form_Map(SymbolMapElem, e, ...) {
if (Symbol* sym = e->key) {
...

Since the 'form_Map' macro only yields non-NULL things by design,
the above assert and check are not needed. I am removing them.

I also replaced: vars->put(sym, arg);
with the equivalent: e->value = arg;
for efficiency.

These changes can also be applied to flattenFunctions.cpp.
I did not do so, to keep that code undisturbed.