Closed agupt closed 8 years ago
Thanks much for the PR.
This is not a complete solution. The full solution would involve ensuring that packageName is a true golang identifier (i.e. starting with a unicodeletter or , followed by a sequence or unicode_letters, unicodedigits or ). This means that the tpkg[idx+1:] should be replaced with a string that converts any unicode character which is not a unicode_letter, unicodedigit or into an _.
I suggest adding a function to do this: func toGoIdentifierPfx(s string) string, and using that in place of strings.Replace(...).
I'm working on codec now, so I will make the full fix on my end and submit. Let me know if you want to handle this soon.
Issue #126