[Bf-blender-cvs] [54d4464a296] functions: remove "small" from some type names
Jacques Lucke
noreply at git.blender.org
Mon Apr 8 16:15:28 CEST 2019
Commit: 54d4464a2965ff98ff3c50b795f30be2e3df2964
Author: Jacques Lucke
Date: Mon Apr 8 16:13:44 2019 +0200
Branches: functions
https://developer.blender.org/rB54d4464a2965ff98ff3c50b795f30be2e3df2964
remove "small" from some type names
===================================================================
M source/blender/functions/backends/llvm/fgraph_ir_generation.cpp
M source/blender/functions/backends/tuple_call/fgraph_tuple_call.cpp
M source/blender/functions/backends/tuple_call/tuple.hpp
M source/blender/functions/core/data_flow_graph.hpp
M source/blender/functions/core/signature.cpp
M source/blender/functions/core/signature.hpp
M source/blender/functions/core/type.hpp
M source/blender/functions/frontends/data_flow_nodes/graph_generation.cpp
M source/blender/functions/frontends/data_flow_nodes/inserters.cpp
M source/blender/functions/frontends/data_flow_nodes/inserters.hpp
===================================================================
diff --git a/source/blender/functions/backends/llvm/fgraph_ir_generation.cpp b/source/blender/functions/backends/llvm/fgraph_ir_generation.cpp
index 592ccb2ee1b..844e47b1721 100644
--- a/source/blender/functions/backends/llvm/fgraph_ir_generation.cpp
+++ b/source/blender/functions/backends/llvm/fgraph_ir_generation.cpp
@@ -7,8 +7,8 @@ namespace FN {
class BuildGraphIR : public LLVMBuildIRBody {
private:
FunctionGraph m_fgraph;
- SmallSocketSetVector m_inputs;
- SmallSocketSetVector m_outputs;
+ SocketSetVector m_inputs;
+ SocketSetVector m_outputs;
SocketSet m_required_sockets;
using SocketValueMap = SmallMap<Socket, llvm::Value *>;
@@ -122,7 +122,7 @@ namespace FN {
LLVMTypeInfo *type_info = type->extension<LLVMTypeInfo>();
BLI_assert(type_info);
- SmallSocketVector targets;
+ SocketVector targets;
for (Socket target : output.targets()) {
if (m_required_sockets.contains(target) && !values.contains(target)) {
BLI_assert(type == target.type());
diff --git a/source/blender/functions/backends/tuple_call/fgraph_tuple_call.cpp b/source/blender/functions/backends/tuple_call/fgraph_tuple_call.cpp
index 15a02dd2579..6675ae25ed3 100644
--- a/source/blender/functions/backends/tuple_call/fgraph_tuple_call.cpp
+++ b/source/blender/functions/backends/tuple_call/fgraph_tuple_call.cpp
@@ -6,8 +6,8 @@ namespace FN {
class InterpretFGraph : public TupleCallBody {
private:
SharedDataFlowGraph m_graph;
- SmallSocketSetVector m_inputs;
- SmallSocketSetVector m_outputs;
+ SocketSetVector m_inputs;
+ SocketSetVector m_outputs;
enum OpCode {
InitTuple,
@@ -344,8 +344,8 @@ namespace FN {
class ExecuteGraph : public TupleCallBody {
private:
SharedDataFlowGraph m_graph;
- SmallSocketSetVector m_inputs;
- SmallSocketSetVector m_outputs;
+ SocketSetVector m_inputs;
+ SocketSetVector m_outputs;
public:
ExecuteGraph(const FunctionGraph &function_graph)
diff --git a/source/blender/functions/backends/tuple_call/tuple.hpp b/source/blender/functions/backends/tuple_call/tuple.hpp
index 46934ef9339..aced424eacd 100644
--- a/source/blender/functions/backends/tuple_call/tuple.hpp
+++ b/source/blender/functions/backends/tuple_call/tuple.hpp
@@ -6,14 +6,14 @@ namespace FN {
class TupleMeta : public RefCountedBase {
private:
- SmallTypeVector m_types;
+ TypeVector m_types;
SmallVector<CPPTypeInfo *> m_type_info;
SmallVector<uint> m_offsets;
uint m_size__data;
uint m_size__data_and_init;
public:
- TupleMeta(const SmallTypeVector &types = {})
+ TupleMeta(const TypeVector &types = {})
: m_types(types)
{
m_size__data = 0;
@@ -28,7 +28,7 @@ namespace FN {
m_size__data_and_init = m_size__data + this->element_amount();
}
- const SmallTypeVector &types() const
+ const TypeVector &types() const
{
return m_types;
}
@@ -120,7 +120,7 @@ namespace FN {
return *tuple;
}
- Tuple(SmallTypeVector types)
+ Tuple(TypeVector types)
: Tuple(SharedTupleMeta::New(types)) {}
/* Has to be implemented explicitely in the future. */
diff --git a/source/blender/functions/core/data_flow_graph.hpp b/source/blender/functions/core/data_flow_graph.hpp
index fd40247a479..40e5e39149f 100644
--- a/source/blender/functions/core/data_flow_graph.hpp
+++ b/source/blender/functions/core/data_flow_graph.hpp
@@ -18,8 +18,8 @@ namespace FN {
using SocketSet = SmallSet<Socket>;
using NodeSet = SmallSet<Node *>;
using NodeSetVector = SmallSetVector<Node *>;
- using SmallSocketVector = SmallVector<Socket>;
- using SmallSocketSetVector = SmallSetVector<Socket>;
+ using SocketVector = SmallVector<Socket>;
+ using SocketSetVector = SmallSetVector<Socket>;
class Socket {
public:
@@ -323,8 +323,8 @@ namespace FN {
public:
FunctionGraph(
SharedDataFlowGraph &graph,
- SmallSocketVector &inputs,
- SmallSocketVector &outputs)
+ SocketVector &inputs,
+ SocketVector &outputs)
: m_graph(graph), m_inputs(inputs), m_outputs(outputs)
{
BLI_assert(graph->frozen());
@@ -335,12 +335,12 @@ namespace FN {
return m_graph;
}
- const SmallSocketSetVector &inputs() const
+ const SocketSetVector &inputs() const
{
return m_inputs;
}
- const SmallSocketSetVector &outputs() const
+ const SocketSetVector &outputs() const
{
return m_outputs;
}
@@ -364,8 +364,8 @@ namespace FN {
private:
SharedDataFlowGraph m_graph;
- SmallSocketSetVector m_inputs;
- SmallSocketSetVector m_outputs;
+ SocketSetVector m_inputs;
+ SocketSetVector m_outputs;
};
diff --git a/source/blender/functions/core/signature.cpp b/source/blender/functions/core/signature.cpp
index 1e03fdfc1d3..5d359b7cbd4 100644
--- a/source/blender/functions/core/signature.cpp
+++ b/source/blender/functions/core/signature.cpp
@@ -2,18 +2,18 @@
namespace FN {
- SmallTypeVector Signature::input_types() const
+ TypeVector Signature::input_types() const
{
- SmallTypeVector types;
+ TypeVector types;
for (const InputParameter ¶m : this->inputs()) {
types.append(param.type());
}
return types;
}
- SmallTypeVector Signature::output_types() const
+ TypeVector Signature::output_types() const
{
- SmallTypeVector types;
+ TypeVector types;
for (const OutputParameter ¶m : this->outputs()) {
types.append(param.type());
}
@@ -21,12 +21,12 @@ namespace FN {
}
bool Signature::has_interface(
- const SmallTypeVector &inputs,
- const SmallTypeVector &outputs) const
+ const TypeVector &inputs,
+ const TypeVector &outputs) const
{
return (true
- && SmallTypeVector::all_equal(this->input_types(), inputs)
- && SmallTypeVector::all_equal(this->output_types(), outputs));
+ && TypeVector::all_equal(this->input_types(), inputs)
+ && TypeVector::all_equal(this->output_types(), outputs));
}
bool Signature::has_interface(
diff --git a/source/blender/functions/core/signature.hpp b/source/blender/functions/core/signature.hpp
index 01771be10b1..bcc681a3741 100644
--- a/source/blender/functions/core/signature.hpp
+++ b/source/blender/functions/core/signature.hpp
@@ -22,8 +22,8 @@ namespace FN {
return m_outputs;
}
- SmallTypeVector input_types() const;
- SmallTypeVector output_types() const;
+ TypeVector input_types() const;
+ TypeVector output_types() const;
template<typename T>
SmallVector<T *> input_extensions() const
@@ -50,8 +50,8 @@ namespace FN {
}
bool has_interface(
- const SmallTypeVector &inputs,
- const SmallTypeVector &outputs) const;
+ const TypeVector &inputs,
+ const TypeVector &outputs) const;
bool has_interface(
const Signature &other) const;
diff --git a/source/blender/functions/core/type.hpp b/source/blender/functions/core/type.hpp
index ba11723ded1..272395559b3 100644
--- a/source/blender/functions/core/type.hpp
+++ b/source/blender/functions/core/type.hpp
@@ -48,7 +48,7 @@ namespace FN {
};
using SharedType = AutoRefCount<Type>;
- using SmallTypeVector = SmallVector<SharedType>;
+ using TypeVector = SmallVector<SharedType>;
} /* namespace FN */
diff --git a/source/blender/functions/frontends/data_flow_nodes/graph_generation.cpp b/source/blender/functions/frontends/data_flow_nodes/graph_generation.cpp
index fc924d9f6d8..c069acc261b 100644
--- a/source/blender/functions/frontends/data_flow_nodes/graph_generation.cpp
+++ b/source/blender/functions/frontends/data_flow_nodes/graph_generation.cpp
@@ -170,8 +170,8 @@ namespace FN { namespace DataFlowNodes {
}
}
- SmallSocketVector input_sockets;
- SmallSocketVector output_sockets;
+ SocketVector input_sockets;
+ SocketVector output_sockets;
if (input_node != nullptr) {
insert_input_node(builder, input_node);
@@ -203,7 +203,7 @@ namespace FN { namespace DataFlowNodes {
BSockets unlinked_inputs;
BNodes unlinked_inputs_nodes;
- SmallSocketVector node_inputs;
+ SocketVector node_inputs;
for (bNode *bnode : bNodeList(&btree->nodes)) {
for (bNodeSocket *bsocket : bSocketList(&bnode->inputs)) {
if (builder.is_data_socket(bsocket)) {
@@ -217,7 +217,7 @@ namespace FN { namespace DataFlowNodes {
}
}
- SmallSocketVector new_origins = inserters.insert_sockets(
+ SocketVector new_origins = inserters.insert_sockets(
builder, unlinked_inputs, unlinked_inputs_nodes);
BLI_assert(unlinked_inputs.size() == new_origins.size());
diff --git a/source/blender/functions/frontends/data_flow_nodes/inserters.cpp b/source/blender/functions/frontends/data_flow_nodes/inserters.cpp
index 91fc208a808..0c7f7aca0be 100644
--- a/source/blender/functions/frontends/data_flow_nodes/inserters.cpp
+++ b/source/blender/functions/frontends/data_flow_nodes/inserters.cpp
@@ -126,7 +126,7 @@ namespace FN { namespace DataFlowNodes {
}
};
- SmallSocketVector GraphInserters::insert_sockets(
+ SocketVector GraphInserters::insert_sockets(
GraphBuilder &builder,
BSockets &bsockets,
BNodes &UNUSED(bnodes))
@@ -152,7 +152,7 @@ namespace FN { namespace DataFlowNodes {
fn->add_body(new SocketLoaderBody(builder.btree(), bsockets, loaders));
Node *node = builder.insert_function(fn);
- SmallSocketVector sockets;
+ SocketVector sockets;
for (Socket output : node->outputs()) {
sockets.append(output);
}
diff --git a/source/blender/functions/frontends/data_flow_nodes/inserters.hpp b/source/blender/functions/frontends/data_flow_nodes/inserters.hpp
index 5a38a1061bf..a644e7f818b 100644
--- a/source/blender/functions/frontends/data_flow_nodes/inserters.hpp
+++ b/source/blender/functions/frontends/data_flow_nodes/inserters.hpp
@@ -53,7 +53,7 @@ namespace FN { namespace DataFlowNodes {
GraphBuilder &builder,
struct bNode *bnode);
- SmallSocketVector insert_sockets(
+ SocketVector insert_sockets(
GraphBuilder &builder,
BSockets &bsockets,
BNodes &bnodes);
More information about the Bf-blender-cvs
mailing list