Translator: Fail earlier if main() is not present. The IR assumes that main() is available on successful parse. Additionally, in preparation for IR removing a check that the AST root is set up, a compile failure to that effect is turned into an assertion. The AST generated before IR is logically only used for validation purposes, so the compiler cannot rely on it to generate an error. Bug: angleproject:349994211 Change-Id: I5d4501b52fed8214213a4ae1dada923decee9a8b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/6991529 Reviewed-by: Yuxin Hu <yuxinhu@google.com> Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org> Reviewed-by: Geoff Lang <geofflang@chromium.org>