Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: Debug Failure. False expression. at tryGetImportFromModuleSpecifier #59845

Open
Andarist opened this issue Sep 4, 2024 · 0 comments Β· May be fixed by #59889
Open

Error: Debug Failure. False expression. at tryGetImportFromModuleSpecifier #59845

Andarist opened this issue Sep 4, 2024 · 0 comments Β· May be fixed by #59889
Assignees
Labels
Bug A bug in TypeScript Fix Available A PR has been opened for this issue

Comments

@Andarist
Copy link
Contributor

Andarist commented Sep 4, 2024

πŸ”Ž Search Terms

unterminated template literal type references

πŸ•— Version & Regression Information

  • This is the behavior in every version I tried

⏯ Playground Link

https://www.typescriptlang.org/play/?ts=5.7.0-dev.20240903#code/C4TwDgpgBAIhGQE4BkIDcIBsA8AVKEAHsBAHYAmAzlJcIgJakDmAfFALxQAGuQA

πŸ’» Code

type DeeperLevel<T extends string> = `T

πŸ™ Actual behavior

When executing "Go to references" on this unterminated template literal it crashes with:

Error: Debug Failure. False expression.

Error: Debug Failure. False expression.
    at tryGetImportFromModuleSpecifier (tsWorker.js:19428:17)
    at getContextNodeForNodeEntry (tsWorker.js:181775:31)
    at nodeEntry (tsWorker.js:181751:18)
    at tsWorker.js:183477:26
    at mapDefined (tsWorker.js:2623:26)
    at tsWorker.js:183472:18
    at flatMap (tsWorker.js:2552:21)
    at getReferencesForStringLiteral (tsWorker.js:183470:28)
    at Object.getReferencedSymbolsForNode (tsWorker.js:182287:20)
    at Object.getReferenceEntriesForNode (tsWorker.js:181919:34)
    at editor.main.js:4190:31

πŸ™‚ Expected behavior

It shouldn't crash

Additional information about the issue

No response

@RyanCavanaugh RyanCavanaugh added the Bug A bug in TypeScript label Sep 4, 2024
@RyanCavanaugh RyanCavanaugh added this to the TypeScript 5.7.0 milestone Sep 4, 2024
@typescript-bot typescript-bot added the Fix Available A PR has been opened for this issue label Sep 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug A bug in TypeScript Fix Available A PR has been opened for this issue
Projects
None yet
4 participants