Skip to content

Commit 146155a

Browse files
committed
fixed indentation, removed unnecessary variables, fixed clang format blocks
1 parent a0076d5 commit 146155a

File tree

2 files changed

+11
-15
lines changed

2 files changed

+11
-15
lines changed

src/conversion.cc

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -166,11 +166,9 @@ void Conversion::AcceptMatlTrades(
166166
for (std::vector<std::pair<Trade<Material>, Material::Ptr>>::const_iterator it =
167167
responses.begin(); it != responses.end(); ++it) {
168168

169-
Material::Ptr mat = it->second;
170-
cyclus::toolkit::MatQuery mq(mat);
171169

172170
// Add material to the input buffer
173-
input.Push(mat);
171+
input.Push(it->second);
174172

175173
}
176174
}
@@ -183,8 +181,7 @@ void Conversion::GetMatlTrades(
183181
for (std::vector<Trade<Material>>::const_iterator it = trades.begin();
184182
it != trades.end(); ++it) {
185183

186-
double requested_qty = it->amt;
187-
Material::Ptr response = output.Pop(requested_qty);
184+
Material::Ptr response = output.Pop(it->amt);
188185

189186
responses.push_back(std::make_pair(*it, response));
190187
}

src/conversion.h

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -87,17 +87,17 @@ class Conversion
8787
}
8888
std::vector<std::string> incommods;
8989

90-
#pragma cyclus var { \
91-
"default": [], \
92-
"doc":"preferences for each of the given commodities, in the same order."\
93-
"Defauts to 1 if unspecified",\
94-
"uilabel":"In Commody Preferences", \
95-
"range": [None, [CY_NEAR_ZERO, CY_LARGE_DOUBLE]], \
96-
"uitype":["oneormore", "range"] \
97-
}
90+
#pragma cyclus var { \
91+
"default": [], \
92+
"doc":"preferences for each of the given commodities, in the same order."\
93+
"Defauts to 1 if unspecified",\
94+
"uilabel":"In Commody Preferences", \
95+
"range": [None, [CY_NEAR_ZERO, CY_LARGE_DOUBLE]], \
96+
"uitype":["oneormore", "range"] \
97+
}
9898
std::vector<double> incommod_prefs;
9999

100-
#pragma cyclus var { \
100+
#pragma cyclus var { \
101101
"default": "", \
102102
"tooltip": "requested composition", \
103103
"doc": "name of recipe to use for material requests, where the default " \
@@ -136,7 +136,6 @@ class Conversion
136136
}
137137
double input_capacity;
138138

139-
// clang-format off
140139
/// this facility holds a certain amount of material
141140
#pragma cyclus var {'capacity': 'input_capacity'}
142141
cyclus::toolkit::ResBuf<cyclus::Material> input;

0 commit comments

Comments
 (0)