Script includes work in buttons but not scripts?

Is this by design? I've started using @include in buttons and it's very useful, but using it in a script gives this error in the log

Error at line 6, position 9
@include inc_quickMessage.js
Conditional compilation is turned off (0x800a0406)

Thanks.

Edit: It seems it has to be on the very first line. Now it works.