Summary
The entrypoint functions arise to allow developers to establish the main flow of execution of a program through a high-level function, which, when compiled, will become a set of instructions with a specific main instruction that allows the computer to follow the expected workflow.
In Bosque, the entrypoint
function is more flexible than in other languages. It allows establishing input parameters and output data types, which is useful for developing serverless functions.
When writing a custom input function or having more than one, it is necessary to specify what the input function should be for the final binary through the --entrypoint
parameter of the ExeGen compiler.
Finally, we have learned more about entrypoint
functions. Now you are able to write your own entrypoint
functions for your Bosque programs. In the next chapter, we will explore the Bosque types and operators in order to expand our knowledge of the language.