Josh Yudaken created THRIFT-4797:
------------------------------------
Summary: Generated Go code produces name collisions on imports
Key: THRIFT-4797
URL: https://issues.apache.org/jira/browse/THRIFT-4797
Project: Thrift
Issue Type: Bug
Components: Go - Compiler
Affects Versions: 0.12.0
Reporter: Josh Yudaken
If two modules have the same name, the produced go code will not compile.
For example:
{code:java}
import (
"github.com/sample/project/common"
"github.com/different/thing/common"
){code}
In go the final component (commons) is used as the name so there is a collision.
This can be fixed by aliasing the modules
{code:java}
import (
common_1 "github.com/sample/project/common"
common_2 "github.com/different/thing/common"
){code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)