[TS] Fix getFullyQualifiedName codegen for typescript (#7730)

#7451 caused getFullyQualifiedName to return a name with underscores,
not periods. Because the fully qualified name is a property of
FlatBuffers, not the language being codegen'd for, it should use
periods. Fixes #7564.

Co-authored-by: Derek Bailey <derekbailey@google.com>
This commit is contained in:
James Kuszmaul
2022-12-22 12:59:40 -08:00
committed by GitHub
parent 449d5649d6
commit e43a80c322
54 changed files with 104 additions and 83 deletions

View File

@@ -35,7 +35,7 @@ dUnderscore():bigint {
}
static getFullyQualifiedName():string {
return 'MyGame_Example_InnerStruct';
return 'MyGame.Example.InnerStruct';
}
static sizeOf():number {
@@ -129,7 +129,7 @@ f(index: number):number|null {
}
static getFullyQualifiedName():string {
return 'MyGame_Example_OuterStruct';
return 'MyGame.Example.OuterStruct';
}
static sizeOf():number {
@@ -271,7 +271,7 @@ e(index: number):bigint|null {
}
static getFullyQualifiedName():string {
return 'MyGame_Example_NestedStruct';
return 'MyGame.Example.NestedStruct';
}
static sizeOf():number {
@@ -407,7 +407,7 @@ g(index: number):bigint|null {
}
static getFullyQualifiedName():string {
return 'MyGame_Example_ArrayStruct';
return 'MyGame.Example.ArrayStruct';
}
static sizeOf():number {
@@ -563,7 +563,7 @@ cUnderscore(obj?:ArrayStruct):ArrayStruct|null {
}
static getFullyQualifiedName():string {
return 'MyGame_Example_ArrayTable';
return 'MyGame.Example.ArrayTable';
}
static startArrayTable(builder:flatbuffers.Builder) {