Skip to content

Commit a24108c

Browse files
committed
Add annotation to the parameter ifwarn in SCAN_BEGIN and SCAN_END
1 parent 3c73446 commit a24108c

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

source/module_base/global_function.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,10 +154,12 @@ static void READ_VALUE(std::ifstream &ifs, T &v)
154154
}
155155

156156
bool SCAN_BEGIN(std::ifstream &ifs, const std::string &TargetName, const bool restart=1, const bool ifwarn=true);
157+
// ifwarn: whether to call GlobalV::ofs_warning when the TargetName is not found, used to avoid invalid warning.
157158
// Mohan warning : the last term can't be written as const bool &restart,
158159
// I don't know why.
159160

160161
void SCAN_END(std::ifstream &ifs, const std::string &TargetName, const bool ifwarn=true);
162+
// ifwarn: whether to call GlobalV::ofs_warning when the TargetName is not found, used to avoid invalid warning.
161163

162164
template<class T>
163165
static inline void DCOPY( const T &a, T &b, const int &dim)

0 commit comments

Comments
 (0)