Fix compiler warning
Fix compiler warning

Rewrite get_attgenerated() to avoid compiler warning if the compiler
does not recognize that elog(ERROR) does not return.

Reported-by: David Rowley <fd082a63ec12854216f305149e697c2550bbe796@2ndquadrant.com>

adam8157/gpdb,lisakowen/gpdb,xinzweb/gpdb,lisakowen/gpdb,adam8157/gpdb,50wu/gpdb,50wu/gpdb,50wu/gpdb,greenplum-db/gpdb,adam8157/gpdb,adam8157/gpdb,adam8157/gpdb,50wu/gpdb,xinzweb/gpdb,greenplum-db/gpdb,xinzweb/gpdb,xinzweb/gpdb,adam8157/gpdb,50wu/gpdb,xinzweb/gpdb,lisakowen/gpdb,xinzweb/gpdb,lisakowen/gpdb,lisakowen/gpdb,lisakowen/gpdb,greenplum-db/gpdb,greenplum-db/gpdb,xinzweb/gpdb,50wu/gpdb,50wu/gpdb,adam8157/gpdb,greenplum-db/gpdb,lisakowen/gpdb,xinzweb/gpdb,greenplum-db/gpdb,50wu/gpdb,greenplum-db/gpdb,greenplum-db/gpdb,adam8157/gpdb,lisakowen/gpdb