Skip to content

Commit 5262dc4

Browse files
author
Dilawar Singh
committed
Added one more missing attribute.
1 parent 7757643 commit 5262dc4

File tree

3 files changed

+10
-7
lines changed

3 files changed

+10
-7
lines changed

pybind11/helper.cpp

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,20 +26,21 @@
2626
// https://pybind11.readthedocs.io/en/stable/advanced/cast/stl.html#binding-stl-containers
2727
// #include "../external/pybind11/include/pybind11/stl_bind.h"
2828

29-
#include "../randnum/randnum.h"
29+
#include "../basecode/header.h"
30+
#include "../basecode/global.h"
3031

31-
#include "../basecode/Cinfo.h"
3232
#include "../builtins/Variable.h"
3333
#include "../mpi/PostMaster.h"
3434
#include "../scheduling/Clock.h"
3535
#include "../shell/Neutral.h"
3636
#include "../shell/Shell.h"
3737
#include "../shell/Wildcard.h"
3838
#include "../utility/strutil.h"
39+
#include "../randnum/randnum.h"
3940

40-
#include "Finfo.h"
4141
#include "helper.h"
4242
#include "pymoose.h"
43+
#include "Finfo.h"
4344

4445
using namespace std;
4546

@@ -101,7 +102,7 @@ ObjId createIdFromPath(string path, string type, unsigned int numData)
101102

102103
string trimmed_path = moose::trim(path);
103104

104-
unsigned int pos = trimmed_path.rfind("/");
105+
auto pos = trimmed_path.rfind("/");
105106
if (pos != string::npos) {
106107
name = trimmed_path.substr(pos + 1);
107108
parent_path = trimmed_path.substr(0, pos);
@@ -345,6 +346,7 @@ ObjId mooseCopy(const py::object& elem, ObjId newParent, string newName,
345346
copyExtMsgs));
346347
}
347348

349+
#if 0
348350
/**
349351
Return a vector of field names of specified finfo type. This is from Subha.
350352
*/
@@ -395,3 +397,5 @@ vector<string> mooseGetFieldNames(string className, string finfoType)
395397
}
396398
return ret;
397399
}
400+
401+
#endif

pybind11/helper.h

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,7 @@ void mooseSetClock(const unsigned int clockId, double dt);
6262

6363
void mooseUseClock(size_t tick, const string& path, const string& field);
6464

65-
vector<string> mooseGetFieldNames(const string& className,
66-
const string& finfoType);
65+
// vector<string> mooseGetFieldNames(const string& className, const string& finfoType);
6766

6867
map<string, string> mooseGetFieldDict(const string& className,
6968
const string& finfoType);

pybind11/pymoose.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -331,7 +331,7 @@ PYBIND11_MODULE(_cmoose, m)
331331
m.def("setClock", &mooseSetClock);
332332
m.def("useClock", &mooseUseClock);
333333
m.def("loadModelInternal", &loadModelInternal);
334-
m.def("getFieldNames", &mooseGetFieldNames);
334+
// m.def("getFieldNames", &mooseGetFieldNames);
335335
m.def("getField",
336336
[](const ObjId &oid, const string &fieldName, const string &ftype) {
337337
// ftype is not needed anymore.

0 commit comments

Comments
 (0)