Possible to disable keyword checking in package names


#1

My domain name ends with a in . So all my package names start with a in. Thus all my API users have to do an import like import `in`.foo.bar instead of import in.foo.bar. It is also a bit annoying to have to type the same way every time I declare a new package.

I presume this is because “in” is a keyword. I could be wrong.

Would it be feasible to make package names like in.foo.bar legal rather than having developers to write import `in`.foo.bar ?

Edit: Multiple edits to fix back quote visibility in html


#2

It’s an interesting idea: we could, in principle, allow unescaped keywords in package declarations and imports, but require escaping when they are used in expressions. Not sure how difficult this is technically.

Meanwhile, I hope that your users rely on the IDE for auto-adding imports to their code, so they don’t have to actually type the escaped names.


#3

With auto import it works but you still have to explain them why they need to see these different characters for my packages only but not for other packages (more so because the same issue does not happen with java code as opposed to kotlin code)