[llvm] [XCOFF] make related SD symbols as isFunction (PR #69553)

James Henderson via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 20 00:43:08 PST 2023


================
@@ -1288,7 +1288,7 @@ Expected<bool> XCOFFSymbolRef::isFunction() const {
   if (CsectAuxRef.getSymbolType() == XCOFF::XTY_LD)
     return true;
 
-  return false;
+  return createError("csect symbol has no valid symbol type.");
----------------
jh7370 wrote:

Please follow the coding standards for error and warning messages here (https://llvm.org/docs/CodingStandards.html#error-and-warning-messages).

Also, grammatically, I'd expect it to be "csect symbol does not have a valid type" or something to that effect. Could you add more context, e.g. what the type actually is?

https://github.com/llvm/llvm-project/pull/69553


More information about the llvm-commits mailing list