Start using vhdl_procedural instead of vhdl_process

This commit is contained in:
Nick Gasson 2008-06-24 19:54:22 +01:00
parent f2aca68b82
commit db992e808f
4 changed files with 8 additions and 8 deletions

View File

@ -112,7 +112,7 @@ static void flush_string(std::ostringstream &ss, stmt_container *container)
* name collision with an existing variable called
* `Verilog_Display_Line' -- do something about this?
*/
int draw_stask_display(vhdl_process *proc, stmt_container *container,
int draw_stask_display(vhdl_procedural *proc, stmt_container *container,
ivl_statement_t stmt, bool newline)
{
if (!proc->get_scope()->have_declared(DISPLAY_LINE)) {

View File

@ -77,7 +77,7 @@ static var_temp_set_t g_assign_vars;
/*
* Called whenever a blocking assignment is made to sig.
*/
void blocking_assign_to(vhdl_process *proc, ivl_signal_t sig)
void blocking_assign_to(vhdl_procedural *proc, ivl_signal_t sig)
{
std::string var(get_renamed_signal(sig));
std::string tmpname(var + "_Var");
@ -104,7 +104,7 @@ void blocking_assign_to(vhdl_process *proc, ivl_signal_t sig)
* the new values visible outside the current process. This should be
* called before any `wait' statement or the end of the process.
*/
void draw_blocking_assigns(vhdl_process *proc, stmt_container *container)
void draw_blocking_assigns(vhdl_procedural *proc, stmt_container *container)
{
var_temp_set_t::const_iterator it;
for (it = g_assign_vars.begin(); it != g_assign_vars.end(); ++it) {

View File

@ -545,8 +545,10 @@ private:
class vhdl_procedural {
public:
stmt_container *get_container() { return &stmts_; }
vhdl_scope *get_scope() { return &scope_; }
protected:
stmt_container stmts_;
vhdl_scope scope_;
};
class vhdl_process : public vhdl_conc_stmt, public vhdl_procedural {
@ -555,9 +557,7 @@ public:
void emit(std::ofstream &of, int level) const;
void add_sensitivity(const char *name);
vhdl_scope *get_scope() { return &scope_; }
private:
vhdl_scope scope_;
std::string name_;
string_list_t sens_;
};

View File

@ -32,11 +32,11 @@ void rename_signal(ivl_signal_t sig, const std::string &renamed);
const vhdl_entity *find_entity_for_signal(ivl_signal_t sig);
const std::string &get_renamed_signal(ivl_signal_t sig);
void blocking_assign_to(vhdl_process *proc, ivl_signal_t sig);
void blocking_assign_to(vhdl_procedural *proc, ivl_signal_t sig);
std::string strip_var(const std::string &str);
void draw_blocking_assigns(vhdl_process *proc, stmt_container *container);
void draw_blocking_assigns(vhdl_procedural *proc, stmt_container *container);
int draw_stask_display(vhdl_process *proc, stmt_container *container,
int draw_stask_display(vhdl_procedural *proc, stmt_container *container,
ivl_statement_t stmt, bool newline = true);
#endif /* #ifndef INC_VHDL_TARGET_H */