Class SafeSymbolAccess

Direct Known Subclasses:
AssignmentStatementOrError, ContainerUnwrapObligations, ObjectAccessExpressionValidOrError

abstract class SafeSymbolAccess extends TypedSymbolAccess
  • Field Details

  • Constructor Details

  • Method Details

    • isAccessUnSafe

      protected boolean isAccessUnSafe(ISymbol calledFromSymbol, String methodName)
    • requiresSafeAccess

      protected boolean requiresSafeAccess(ISymbol calledFromSymbol, String methodName)
      Whether methodName on calledFromSymbol is a container-unwrap that needs a preceding safety check (Optional.get, Result.ok/error, Iterator.next on a symbol the marker has flagged) — i.e. an unwrap obligation exists here, independent of whether it is discharged. isAccessUnSafe(ISymbol, String) then answers whether that obligation is undischarged (unguarded). Split out so the obligation census can count the obligation and read its discharge from the same source of truth the E08030 checker uses.