@@ -35,7 +35,7 @@ using llvm::formatv;
3535// / on each element doesn't return a string.
3636template <typename ForwardIterator, typename UnaryFunctor,
3737 typename NullaryFunctor>
38- inline LogicalResult
38+ static inline LogicalResult
3939interleaveWithError (ForwardIterator begin, ForwardIterator end,
4040 UnaryFunctor eachFn, NullaryFunctor betweenFn) {
4141 if (begin == end)
@@ -52,16 +52,16 @@ interleaveWithError(ForwardIterator begin, ForwardIterator end,
5252}
5353
5454template <typename Container, typename UnaryFunctor, typename NullaryFunctor>
55- inline LogicalResult interleaveWithError (const Container &c,
56- UnaryFunctor eachFn,
57- NullaryFunctor betweenFn) {
55+ static inline LogicalResult interleaveWithError (const Container &c,
56+ UnaryFunctor eachFn,
57+ NullaryFunctor betweenFn) {
5858 return interleaveWithError (c.begin (), c.end (), eachFn, betweenFn);
5959}
6060
6161template <typename Container, typename UnaryFunctor>
62- inline LogicalResult interleaveCommaWithError (const Container &c,
63- raw_ostream &os,
64- UnaryFunctor eachFn) {
62+ static inline LogicalResult interleaveCommaWithError (const Container &c,
63+ raw_ostream &os,
64+ UnaryFunctor eachFn) {
6565 return interleaveWithError (c.begin (), c.end (), eachFn, [&]() { os << " , " ; });
6666}
6767
@@ -1787,7 +1787,7 @@ LogicalResult CppEmitter::emitType(Location loc, Type type) {
17871787 case 16 : {
17881788 if (llvm::isa<Float16Type>(type))
17891789 return (os << " _Float16" ), success ();
1790- else if (llvm::isa<BFloat16Type>(type))
1790+ if (llvm::isa<BFloat16Type>(type))
17911791 return (os << " __bf16" ), success ();
17921792 else
17931793 return emitError (loc, " cannot emit float type " ) << type;
0 commit comments