Checks that all block definitions are closed.
160328
private void checkBlockDefinitionsComplete() throws MiniTemplator.TemplateSyntaxException {
        for (int blockNo = 0; blockNo < blockTabCnt; blockNo++) {
            BlockTabRec btr = blockTab[blockNo];
            if (btr.definitionIsOpen) {
                throw new MiniTemplator.TemplateSyntaxException(
                        "Missing $EndBlock command in template for block \"" + btr.blockName + "\".");
            }
        }
        if (currentNestingLevel != 0) {
            throw new MiniTemplator.TemplateSyntaxException("Block nesting level error at end of template.");
        }
    }
1354748
def have_all_block_data(self):
        
        if not (self.num_blocks_received == self.num_blocks_requested):
            log.debug("num blocks received = %s, num requested = %s" % (self.num_blocks_received, self.num_blocks_requested))
            return False

        return True
691072
@Trivial
    private void stateClosed() {
        rollingWindow.clear();
        state.set(State.CLOSED);
        metricRecorder.reportCircuitClosed();
        if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
            Tr.debug(tc, "Transitioned to Closed state");
        }
    }
889119
def is_closed(self):
        
        return (self.state == SESSION_STATE.CLOSED 
                or self.state == SESSION_STATE.CLOSING)
1315304
private boolean removeUnreachable(Block block) {
    List<Statement> stmts = block.getStatements();
    for (int i = 0; i < stmts.size(); i++) {
      Statement stmt = stmts.get(i);
      if (stmt instanceof ReturnStatement
          || (stmt instanceof Block && removeUnreachable((Block) stmt))) {
        stmts.subList(i + 1, stmts.size()).clear();
        return true;
      }
    }
    return false;
  }
240636
void checkLostBlocks(List<Block> blocksLostChecksum,
      List<Block> blocksLostStripe, Path p, Codec codec)
      throws IOException {
    StringBuilder message = new StringBuilder();
    if (blocksLostChecksum.size() > 0) {
      message.append("Lost " + blocksLostChecksum.size() +
          " checksums in blocks:");
      for (Block blk : blocksLostChecksum) {
        message.append(" ");
        message.append(blk.toString());
      }
    }
    if (blocksLostStripe.size() > 0) {
      message.append("Lost " + blocksLostStripe.size() +
          " stripes in blocks:");
      for (Block blk : blocksLostStripe) {
        message.append(" ");
        message.append(blk.toString());
      }
    }
    if (message.length() == 0)
      return;
    message.append(" in file " + p);
    throw new IOException(message.toString());
  }
440799
public boolean closeIfCached(T geoPackage) {
		boolean closed = false;
		if (geoPackage != null) {
			T cached = get(geoPackage.getName());
			if (cached != null && cached == geoPackage) {
				closed = close(geoPackage.getName());
			}
		}
		return closed;
	}
20075
public boolean isClosed()
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
        {
            SibTr.entry(tc, "isClosed", this);
            SibTr.exit(tc, "isClosed", Boolean.valueOf(_closed));
        }
        return _closed;
    }
476286
def is_block(bin_list):

    
    id_set = set((my_bin[1] for my_bin in bin_list))
    start_id, end_id = min(id_set), max(id_set)
    return id_set == set(range(start_id, end_id + 1))
1172790
def closed(self):
        """"""
        closed = self._closing or self._closed
        if not closed and self._reader and self._reader.at_eof():
            self._closing = closed = True
            self._loop.call_soon(self._do_close, None)
        return closed
987656
def goes_requires(self, regs):
        
        if len(self) and self.mem[-1].inst == 'call' and self.mem[-1].condition_flag is None:
            for block in self.calls:
                if block.is_used(regs, 0):
                    return True

                d = block.destroys()
                if not len([x for x in regs if x not in d]):
                    return False  # If all registers are destroyed then they're not used

        for block in self.goes_to:
            if block.is_used(regs, 0):
                return True

        return False
303241
function isClosed(connId) {
  const connObj = connStatus[connId];
  return (connObj && Object.keys(connObj).length === 0);
}
656377
public boolean hasDeletedSlots() {
		long blkNum = (Long) getVal(OFFSET_LDS_BLOCKID, BIGINT).asJavaVal();
		return blkNum != NO_SLOT_BLOCKID ? true : false;
	}
1334433
def logs_blocks_sanity_check(from_block: BlockSpecification, to_block: BlockSpecification) -> None:
    """"""
    is_valid_from = isinstance(from_block, int) or isinstance(from_block, str)
    assert is_valid_from, 'event log from block can be integer or latest,pending, earliest'
    is_valid_to = isinstance(to_block, int) or isinstance(to_block, str)
    assert is_valid_to, 'event log to block can be integer or latest,pending, earliest'
735231
def end_block(self):
        """"""
        self.current_indent -= 1

        # If we did not add a new line automatically yet, now it's the time!
        if not self.auto_added_line:
            self.writeln()
            self.auto_added_line = True
1304385
def _sanity_check_query_root_block(ir_blocks):
    """"""
    if not isinstance(ir_blocks[0], QueryRoot):
        raise AssertionError(u'The first block was not QueryRoot: {}'.format(ir_blocks))
    for block in ir_blocks[1:]:
        if isinstance(block, QueryRoot):
            raise AssertionError(u'Found QueryRoot after the first block: {}'.format(ir_blocks))
1295810
public boolean isEnclosedBy(ClassSymbol clazz) {
        for (Symbol sym = this; sym.kind != PCK; sym = sym.owner)
            if (sym == clazz) return true;
        return false;
    }