How would you know whether a transaction has an output in the previous block if you don't know what transactions were in that block? Additionally how would you know whether an unconfirmed transaction which uses an older output was not confirmed in the last block?