Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
Description
PROBLEM
The example below results in a Dart analyzer error since the reference to b.Foo is ambiguous in the generated code.
FIX
Name imports for dependencies to make references explicit.
EXAMPLE
thrift -r --gen dart a.thrift
a.thrift
include "b.thrift" namespace dart a /**@ Foo in a*/ struct Foo { 1:string name } /**@ Bar in a*/ struct Bar { 1:Foo aFoo, 2:b.Foo bFoo }
b.thrift
namespace dart b
/**@ Foo in b*/
struct Foo {
1:string name
}