specifically i get, `a non-expression cannot be re...
# intellij
s
specifically i get,
a non-expression cannot be replaced with an expression
e
you could try doing regex
I guess the trick is that you need to match every
Copy code
@Slf4J
class Whatever { 
   val field = ...
and be replaced to
Copy code
class Whatever { 
   val logger = KotlinLogging.logger { }
   val field = ...
s
well it's even easier than that actually, since logger is top level as well
e
even better
s
or, the end state is for it to be roughly where the @Slf4j was
e
but regex will do it for you
s
i don't know how to do that within structural search & replace
i am trying to create an inspection, so it has to be done through this
e
oh
I thought you just need this to be replaced and in that case you could just do plain text search & replace
s
there must be some syntax to get it to ignore. like, do i need to wrap it in quotes or something?