Skip to content

When more than one unique symbol is found in a source locator, decide what to do #69

Open
@Ocramius

Description

Following code is perfectly valid in BetterReflection, but the outcome is rather unexpected:

class Foo {}
class Foo {}
function bar() {}
function bar() {}
const BAZ = 'baz';
const BAZ = 'baz';

Things that better reflection could do:

  • throw an exception if an API such as getClass($name) is used (expecting 1 result, found 2)
  • return all reflections if an API such as getClassesByName($name) is used (2 results)

This is yet to be decided.

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions