1

Say I have a typealias

package server.user

typealias UserId = Int

Then I want to write a function in another package

package client.game

fun getUser(userId: UserId): User

When I get to

fun getUser(us

It autosuggests userId: UserId, and if I follow this suggestion, it adds the following

fun getUser(userId: UserId /* = kotlin.Int */

My question then is: How do I get IDEA to stop adding this comment?

hallundbæk
  • 517
  • 5
  • 10
  • 1
    I couldn't reproduce the issue. It could be my IDE settings. Are you sure the comments are real? IDEA tends to add type hints and parameter hints, but those are visual aids and not part of the code. – k314159 Dec 21 '21 at 15:08
  • Just tried reproducing, and it only happens if you reference it from another package. I have edited the question to reflect this. – hallundbæk Dec 21 '21 at 16:10
  • still not reproducible for me – sidgate Dec 22 '21 at 04:27
  • 1
    It's a bug, please watch https://youtrack.jetbrains.com/issue/KTIJ-20341 for updates on this problem. – Alexey Belkov Dec 27 '21 at 09:49

0 Answers0