Skip to content

Commit e88b523

Browse files
Use list comprehension when objects are created
This allows for unique objects rather than pointers to the same object.
1 parent 03966d3 commit e88b523

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

ciw/import_params.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -185,9 +185,7 @@ def fill_out_dictionary(params):
185185
class_name: [None] * number_of_nodes
186186
for class_name in class_names
187187
},
188-
"service_disciplines": [
189-
ciw.disciplines.FIFO
190-
] * number_of_nodes,
188+
"service_disciplines": [ciw.disciplines.FIFO for _ in range(number_of_nodes)],
191189
"system_capacity": float('inf')
192190
}
193191

0 commit comments

Comments
 (0)