Generalize "main" to a settable entry point name.

This commit is contained in:
John Kessenich
2016-03-12 18:17:47 -07:00
parent 6cc7674b6d
commit 4d65ee31a6
8 changed files with 38 additions and 8 deletions

View File

@@ -205,9 +205,9 @@ public:
void setBuildPoint(Block* bp) { buildPoint = bp; }
Block* getBuildPoint() const { return buildPoint; }
// Make the main function. The returned pointer is only valid
// Make the entry-point function. The returned pointer is only valid
// for the lifetime of this builder.
Function* makeMain();
Function* makeEntrypoint(const char*);
// Make a shader-style function, and create its entry block if entry is non-zero.
// Return the function, pass back the entry.