pass as reference
This commit is contained in:
2
ml.cpp
2
ml.cpp
@@ -1768,7 +1768,7 @@ void load_std_lib(MlEnvironment &env) {
|
||||
}
|
||||
|
||||
// Does this environment, or its parent environment, have a variable?
|
||||
bool MlEnvironment::has(std::string name) const {
|
||||
bool MlEnvironment::has(const std::string &name) const {
|
||||
// Find the value in the map
|
||||
std::map<std::string, MlValue>::const_iterator itr = defs.find(name);
|
||||
if (itr != defs.end())
|
||||
|
||||
Reference in New Issue
Block a user