src/Viserio/Component/Container/Container.php
public function resolve($subject, array $parameters = [])
    {
        if (\is_string($subject) && isset($this->contextualParameters[$subject])) {
            $contextualParameters = $this->contextualParameters[$subject];

            foreach ($contextualParameters as $key => $value) {
                if ($value instanceof Closure) {
                    $contextualParameters[$key] = $value($this);
                }
            }

            $parameters = \array_replace($contextualParameters, $parameters);
        }

        if ($this->has($subject)) {
            return $this->resolveBound($subject, $parameters);
        }

        return $this->resolveNonBound($subject, $parameters);
    }
public function resolve($subject, array $parameters = [])
    {
        if (\is_string($subject) && isset($this->contextualParameters[$subject])) {
            $contextualParameters = $this->contextualParameters[$subject];

            foreach ($contextualParameters as $key => $value) {
                if ($value instanceof Closure) {
                    $contextualParameters[$key] = $value($this);
                }
            }

            $parameters = \array_replace($contextualParameters, $parameters);
        }

        if ($this->has($subject)) {
            return $this->resolveBound($subject, $parameters);
        }

        return $this->resolveNonBound($subject, $parameters);
    }
{@inheritdoc}