Bash++
Bash++ compiler internal documentation
|
A struct to hold (compiled) code segments. More...
#include <bpp_codegen.h>
Public Member Functions | |
std::string | full_code () const |
Return the full code segment as a single string. More... | |
Public Attributes | |
std::string | pre_code |
std::string | code |
std::string | post_code |
A struct to hold (compiled) code segments.
Much of the code generation in the compiler is done using code segments. A code segment consists of three parts:
Generally, the pre_code and post_code are used to set up and clean up the environment in which the main code will run.
|
inline |
Return the full code segment as a single string.
This function concatenates the pre_code, code, and post_code, and adds separating newlines only if necessary.
std::string bpp::code_segment::code |
std::string bpp::code_segment::post_code |
std::string bpp::code_segment::pre_code |