mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-22 02:35:48 -05:00
getSymbolDisplayPartsDocumentationAndSymbolKind: use actual symbol.flags for getAliasedSymbol
Fixes #35347.
This commit is contained in:
@@ -379,7 +379,8 @@ namespace ts.SymbolDisplay {
|
||||
}
|
||||
}
|
||||
}
|
||||
if (symbolFlags & SymbolFlags.Alias) {
|
||||
// don't use symbolFlags since getAliasedSymbol requires the flag on the symbol itself
|
||||
if (symbol.flags & SymbolFlags.Alias) {
|
||||
prefixNextMeaning();
|
||||
if (!hasAddedSymbolInfo) {
|
||||
const resolvedSymbol = typeChecker.getAliasedSymbol(symbol);
|
||||
|
||||
24
tests/cases/fourslash/quickInfoJSExport.ts
Normal file
24
tests/cases/fourslash/quickInfoJSExport.ts
Normal file
@@ -0,0 +1,24 @@
|
||||
/// <reference path="fourslash.ts" />
|
||||
|
||||
// GH #35347
|
||||
|
||||
// @Filename: a.js
|
||||
// @allowJs: true
|
||||
//// /**
|
||||
//// * @enum {string}
|
||||
//// */
|
||||
//// const testString = {
|
||||
//// one: "1",
|
||||
//// two: "2"
|
||||
//// };
|
||||
////
|
||||
//// export { test/**/String };
|
||||
|
||||
verify.quickInfoAt("",
|
||||
`type testString = string
|
||||
(alias) type testString = any
|
||||
(alias) const testString: {
|
||||
one: string;
|
||||
two: string;
|
||||
}
|
||||
export testString`);
|
||||
Reference in New Issue
Block a user