Fixup all doxygen warnings
No idea why the operator<<() functions have started moaning now.
Change-Id: I338b96c53888f4ddb8e42283a6dcda7708e567f0
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/47431
Commit-Queue: Ben Clayton <bclayton@google.com>
Reviewed-by: Antonio Maiorano <amaiorano@google.com>
diff --git a/Doxyfile b/Doxyfile
index 0571728..6e467e1 100644
--- a/Doxyfile
+++ b/Doxyfile
@@ -787,7 +787,6 @@
INPUT = README.md \
CODE_OF_CONDUCT.md \
- CONTRIBUTING.md \
src
# This tag can be used to specify the character encoding of the source files
diff --git a/src/ast/access_control.h b/src/ast/access_control.h
index a8a740f..4539cd1 100644
--- a/src/ast/access_control.h
+++ b/src/ast/access_control.h
@@ -30,6 +30,9 @@
kReadWrite
};
+/// @param out the std::ostream to write to
+/// @param access the AccessControl
+/// @return the std::ostream so calls can be chained
std::ostream& operator<<(std::ostream& out, AccessControl access);
} // namespace ast
diff --git a/src/ast/binary_expression.h b/src/ast/binary_expression.h
index 9c9d840..6eec7ae 100644
--- a/src/ast/binary_expression.h
+++ b/src/ast/binary_expression.h
@@ -182,6 +182,8 @@
}
}
+/// @returns the human readable name of the given BinaryOp
+/// @param op the BinaryOp
constexpr const char* FriendlyName(BinaryOp op) {
switch (op) {
case BinaryOp::kNone:
@@ -226,6 +228,9 @@
return "INVALID";
}
+/// @param out the std::ostream to write to
+/// @param op the BinaryOp
+/// @return the std::ostream so calls can be chained
inline std::ostream& operator<<(std::ostream& out, BinaryOp op) {
out << FriendlyName(op);
return out;
diff --git a/src/ast/builtin.h b/src/ast/builtin.h
index 0305958..0e8151d 100644
--- a/src/ast/builtin.h
+++ b/src/ast/builtin.h
@@ -41,6 +41,9 @@
kPointSize,
};
+/// @param out the std::ostream to write to
+/// @param builtin the Builtin
+/// @return the std::ostream so calls can be chained
std::ostream& operator<<(std::ostream& out, Builtin builtin);
} // namespace ast
diff --git a/src/ast/pipeline_stage.h b/src/ast/pipeline_stage.h
index 3733c8c..ccaa8c9 100644
--- a/src/ast/pipeline_stage.h
+++ b/src/ast/pipeline_stage.h
@@ -23,6 +23,9 @@
/// The pipeline stage
enum class PipelineStage { kNone = -1, kVertex, kFragment, kCompute };
+/// @param out the std::ostream to write to
+/// @param stage the PipelineStage
+/// @return the std::ostream so calls can be chained
std::ostream& operator<<(std::ostream& out, PipelineStage stage);
} // namespace ast
diff --git a/src/ast/storage_class.h b/src/ast/storage_class.h
index 3b89986..a6e5983 100644
--- a/src/ast/storage_class.h
+++ b/src/ast/storage_class.h
@@ -35,11 +35,15 @@
};
/// @returns true if the StorageClass is host-shareable
+/// @param sc the StorageClass
/// @see https://gpuweb.github.io/gpuweb/wgsl.html#host-shareable
inline bool IsHostShareable(StorageClass sc) {
return sc == ast::StorageClass::kUniform || sc == ast::StorageClass::kStorage;
}
+/// @param out the std::ostream to write to
+/// @param sc the StorageClass
+/// @return the std::ostream so calls can be chained
std::ostream& operator<<(std::ostream& out, StorageClass sc);
} // namespace ast
diff --git a/src/ast/test_helper.h b/src/ast/test_helper.h
index d7a229e..2bfc79b 100644
--- a/src/ast/test_helper.h
+++ b/src/ast/test_helper.h
@@ -21,11 +21,14 @@
namespace tint {
namespace ast {
-/// Helper class for testing
+/// Helper base class for testing
template <typename BASE>
class TestHelperBase : public BASE, public ProgramBuilder {};
+
+/// Helper class for testing that derives from testing::Test.
using TestHelper = TestHelperBase<testing::Test>;
+/// Helper class for testing that derives from `T`.
template <typename T>
using TestParamHelper = TestHelperBase<testing::TestWithParam<T>>;
diff --git a/src/ast/unary_op.h b/src/ast/unary_op.h
index 8a6b9f7..04d754d 100644
--- a/src/ast/unary_op.h
+++ b/src/ast/unary_op.h
@@ -23,6 +23,9 @@
/// The unary op
enum class UnaryOp { kNegation = 0, kNot };
+/// @param out the std::ostream to write to
+/// @param mod the UnaryOp
+/// @return the std::ostream so calls can be chained
std::ostream& operator<<(std::ostream& out, UnaryOp mod);
} // namespace ast
diff --git a/src/semantic/member_accessor_expression.h b/src/semantic/member_accessor_expression.h
index 4865b77..2f98821 100644
--- a/src/semantic/member_accessor_expression.h
+++ b/src/semantic/member_accessor_expression.h
@@ -58,6 +58,7 @@
/// Constructor
/// @param declaration the AST node
/// @param type the resolved type of the expression
+ /// @param statement the statement that owns this expression
/// @param member the structure member
StructMemberAccess(ast::MemberAccessorExpression* declaration,
type::Type* type,
@@ -81,6 +82,7 @@
/// Constructor
/// @param declaration the AST node
/// @param type the resolved type of the expression
+ /// @param statement the statement that
/// @param indices the swizzle indices
Swizzle(ast::MemberAccessorExpression* declaration,
type::Type* type,