OpenBullet2 icon indicating copy to clipboard operation
OpenBullet2 copied to clipboard

[Bug]: ConstantString / error CS1010: Newline in constant

Open APT-ZERO opened this issue 2 years ago • 2 comments

Version of the software

0.2.4

Operating system

Windows 10

Browser / Native

Chrome

What happened?

A bug happened!

[IDLE] CompilationErrorException: (3,64): error CS1010: Newline in constant

Relevant LoliCode if needed

BLOCK:ConstantString
  value = $"a\n`]\nd\n[e]"
  => VAR @constantStringOutput
ENDBLOCK

APT-ZERO avatar Mar 03 '23 08:03 APT-ZERO

Hello, thanks for pointing out the bug. I just wanted to say that without the interpolated mode (a.k.a. the leading $) it works as intended. I will have to look into this.

openbullet avatar Mar 04 '23 23:03 openbullet

Use \\n instead \n then it could be fixed.

onisoc avatar Mar 29 '23 03:03 onisoc

After testing I confirm you need to use \\n. If you use Stacker, it automatically converts \n to \\n but if you write it in LoliCode you have to remember to do it yourself. So props to @onisoc for their comment.

openbullet avatar Jun 06 '24 20:06 openbullet