Disallow function calls to main().

In practice, calls to main are not meaningful:
- If main is called in live code, it's recursive
- If main is called in dead code, it's eliminated

However, if optimization/dead-stripping is turned off, the dead-code
case emits bad code in our GLSL/Metal backends. Rather than add a
special case to the backends to work around an error in a meaningless
edge case, we now reject the function call entirely.

Prototyping main() is, as far as I can tell, harmless, so this
continues to be allowed.

Change-Id: I69916840c06810cd948bd74ff168ada1c4fc74f8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/557578
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Arman Uguray <armansito@google.com>
Commit-Queue: Arman Uguray <armansito@google.com>
7 files changed