Skip to content

Failure in 'getNavigationBarItems' when mixing computed/non-computed property declarations #7301

@DanielRosenwasser

Description

@DanielRosenwasser

This code

class C {
    foo;
    ["bar"]: string;
}

causes the following error:

getNavigationBarItems('C:\Users\drosen\AppData\Local\Temp\~vs6F46.ts')

StackTrace:

TypeError: Unable to get property 'localeCompare' of undefined or null reference
   at Anonymous function (:42182:25)
   at sortNodes (:42180:17)
   at createClassItem (:42442:25)
   at createTopLevelItem (:42381:25)
   at getItemsWorker (:42243:21)
   at getNavigationBarItems (:42074:13)
   at getNavigationBarItems (:52212:13)
   at Anonymous function (:54667:100)
   at simpleForwardCall (:54385:9)
   at forwardJSONCall (:54401:13)
   at forwardJSONCall (:54447:13)
   at getNavigationBarItems (:54667:13)

Metadata

Metadata

Assignees

No one assigned

    Labels

    BugA bug in TypeScriptFixedA PR has been merged for this issue

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions