dependency: don't try and expand yourself.
dependency: don't try and expand yourself.

This can happen on e.g. fossil where the dependency HEAD requires having
an install of fossil in order to check it out. Bit of a silly edge case
but this handles it.

Fixes Homebrew/homebrew#25605

Homebrew/brew,jmsundar/brew,MikeMcQuaid/brew,reitermarkus/brew,mgrimes/brew,mistydemeo/homebrew,Homebrew/brew,vitorgalvao/brew,rwhogg/brew,gregory-nisbet/brew,alyssais/brew,bfontaine/brew,Homebrew/brew,aw1621107/brew,gordonmcshane/homebrew,Linuxbrew/brew,MikeMcQuaid/brew,konqui/brew,tonyg/homebrew,muellermartin/dist,sjackman/homebrew,hanxue/linuxbrew,reelsense/brew,palxex/brew,maxim-belkin/brew,palxex/brew,DomT4/brew,alyssais/brew,hanxue/linuxbrew,jmsundar/brew,gordonmcshane/homebrew,claui/brew,JCount/brew,zmwangx/brew,maxim-belkin/brew,staticfloat/brew,AnastasiaSulyagina/brew,reitermarkus/brew,toonetown/homebrew,JCount/brew,reitermarkus/brew,rwhogg/brew,amar-laksh/brew_sudo,hanxue/linuxbrew,tonyg/homebrew,toonetown/homebrew,zmwangx/brew,MikeMcQuaid/brew,bfontaine/brew,mistydemeo/homebrew,Linuxbrew/brew,zmwangx/brew,sjackman/homebrew,konqui/brew,vitorgalvao/brew,mistydemeo/homebrew,toonetown/homebrew,alyssais/brew,reelsense/brew,nandub/brew,EricFromCanada/brew,reitermarkus/brew,Linuxbrew/brew,EricFromCanada/brew,rwhogg/brew,bfontaine/brew,pseudocody/brew,jmsundar/brew,konqui/brew,JCount/brew,mahori/brew,MikeMcQuaid/brew,DomT4/brew,DomT4/brew,mahori/brew,amar-laksh/brew_sudo,mahori/brew,konqui/brew,vitorgalvao/brew,gregory-nisbet/brew,Linuxbrew/brew,AnastasiaSulyagina/brew,sjackman/homebrew,gregory-nisbet/brew,pseudocody/brew,aw1621107/brew,nandub/brew,amar-laksh/brew_sudo,staticfloat/brew,sjackman/homebrew,gordonmcshane/homebrew,mgrimes/brew,aw1621107/brew,mahori/brew,AnastasiaSulyagina/brew,claui/brew,nandub/brew,Homebrew/brew,EricFromCanada/brew,ilovezfs/brew,palxex/brew,reelsense/brew,claui/brew,ilovezfs/brew,EricFromCanada/brew,JCount/brew,DomT4/brew,tonyg/homebrew,pseudocody/brew,ilovezfs/brew,nandub/brew,muellermartin/dist,staticfloat/brew,mgrimes/brew,vitorgalvao/brew,muellermartin/dist,maxim-belkin/brew,claui/brew