Skip to content
This repository has been archived by the owner on Dec 1, 2024. It is now read-only.

GroupUseStatementLinter does not work correctly with namespace blocks #307

Open
fredemmott opened this issue Jul 15, 2020 · 0 comments
Open

Comments

@fredemmott
Copy link
Contributor

in.hack

namespace Foo {
  use type SomeOtherNS\Herp;
  use type SomeOtherNS\Derp;
  function do_stuff(Herp $_, Derp $_): void {}
}

namespace Bar {
  use type SomeOtherNS\Herp;
  use type SomeOtherNS\Derp;
  function do_stuff(Herp $_, Derp $_): void {}
}

out.hack

namespace Foo {
  use type SomeOtherNS\{Derp, Herp};
  function do_stuff(Herp $_, Derp $_): void {}
}

namespace Bar {
  function do_stuff(Herp $_, Derp $_): void {}
}

problem

Herp and Derp are no longer usable in namespace Bar

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant