ReadMethodGenerator: use int instead of bool as conditional.

To reuse array length as the condition.
Merge branch 'master' of github.com:antmicro/Migrant