Use preincrement instead of post in for loop incr
This commit is contained in:
parent
ea26587b5e
commit
26c01e7f0a
4
pform.cc
4
pform.cc
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 1998-2024 Stephen Williams (steve@icarus.com)
|
||||
* Copyright (c) 1998-2025 Stephen Williams (steve@icarus.com)
|
||||
* Copyright CERN 2013 / Stephen Williams (steve@icarus.com)
|
||||
*
|
||||
* This source code is free software; you can redistribute it
|
||||
|
|
@ -1482,7 +1482,7 @@ void pform_endmodule(const char*name, bool inside_celldefine,
|
|||
void pform_genvars(const struct vlltype&li, list<pform_ident_t>*names)
|
||||
{
|
||||
list<pform_ident_t>::const_iterator cur;
|
||||
for (cur = names->begin(); cur != names->end() ; *cur++) {
|
||||
for (cur = names->begin(); cur != names->end() ; ++cur) {
|
||||
PGenvar*genvar = new PGenvar();
|
||||
FILE_NAME(genvar, li);
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
/*
|
||||
* Managing global state for the VHDL code generator.
|
||||
*
|
||||
* Copyright (C) 2009 Nick Gasson (nick@nickg.me.uk)
|
||||
* Copyright (C) 2009-2025 Nick Gasson (nick@nickg.me.uk)
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
|
|
@ -256,7 +256,7 @@ static bool same_scope_type_name(ivl_scope_t a, ivl_scope_t b)
|
|||
if (nparams_a != nparams_b)
|
||||
return false;
|
||||
|
||||
for (unsigned i = 0; i < nparams_a; i++) {
|
||||
for (unsigned i = 0; i < nparams_a; ++i) {
|
||||
ivl_parameter_t param_a = ivl_scope_param(a, i);
|
||||
ivl_parameter_t param_b = ivl_scope_param(b, i);
|
||||
|
||||
|
|
@ -304,7 +304,7 @@ static bool same_scope_type_name(ivl_scope_t a, ivl_scope_t b)
|
|||
*/
|
||||
bool seen_this_scope_type(ivl_scope_t s)
|
||||
{
|
||||
for (auto cur = g_default_scopes.begin() ; cur != g_default_scopes.end() ; cur++) {
|
||||
for (auto cur = g_default_scopes.begin() ; cur != g_default_scopes.end() ; ++cur) {
|
||||
if (same_scope_type_name(s, *cur))
|
||||
return true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue