# The need for ! operator seems verbose

**URL:** https://discuss.kotlinlang.org/t/the-need-for-operator-seems-verbose/997
**Category:** Uncategorized
**Created:** [November 27, 2012, 11:23pm UTC](https://discuss.kotlinlang.org/t/the-need-for-operator-seems-verbose/997 "2012-11-27T23:23:57Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![saltnlight5](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.kotlinlang.org/saltnlight5/32/1525_2.png) [@saltnlight5](https://discuss.kotlinlang.org/u/saltnlight5)
#### Post date: [November 27, 2012, 11:23pm UTC](https://discuss.kotlinlang.org/t/the-need-for-operator-seems-verbose/997/1 "2012-11-27T23:23:57Z")

</div>

Hi,

I am a novice user on Kotlin, so perhaps it’s just me not getting used to the language syntax, but when I try to integrate with existing Java libraries, I can’t but notice many forced usage of “!!.” operators all over the places, and it obstruct code reading.

Another way from doc is to use “if (var != null)”, but it’s so verbose, I don’t want to use it.

I understand there is an article says to use jetbrian’s @NotNull annotation to supress this, but it seems applicable to IDEA IDE only. This doesn’t sound like an good option to me.

So is this how Kotlin intend to be used when integrating with Java? I understand and see the good purpose of Non-NULL feature of Kotlin, but enforcing this on exiting Java library is very annoying to me. Is it just my inexperience with Kotlin, or other users feel the same?

Thanks,  
Zemian

---

<div class="post-metadata">

### Author: ![nyoungman](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.kotlinlang.org/nyoungman/32/1601_2.png) [@nyoungman](https://discuss.kotlinlang.org/u/nyoungman)
#### Post date: [November 28, 2012, 4:46am UTC](https://discuss.kotlinlang.org/t/the-need-for-operator-seems-verbose/997/2 "2012-11-28T04:46:51Z")

</div>

Hi Zemian,

Having watched some of the [talks](http://confluence.jetbrains.net/display/Kotlin/Talks+and+Publications), I’ve heard that Jetbrains is working on [tooling](https://github.com/abreslav/kannotator) so that annotating existing Java libraries won’t be necessary. It will inspect the byte code and determine if the types are nullable or not.

The !! operator is purposefully verbose, but once the tooling is in place, I don’t imagine it would be often necessary.

Nathan.

---

<div class="post-metadata">

### Author: ![saltnlight5](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.kotlinlang.org/saltnlight5/32/1525_2.png) [@saltnlight5](https://discuss.kotlinlang.org/u/saltnlight5)
#### Post date: [November 29, 2012, 3:11am UTC](https://discuss.kotlinlang.org/t/the-need-for-operator-seems-verbose/997/3 "2012-11-29T03:11:23Z")

</div>

Thank you for the links Nathan. I will check them out.
