Hello,

I ran into a bit of a headscratcher today when moving a commented line changed the output of my fractal formula. I eventually figured out that I had two comments, the first of which was a line ending in \ (the continuation character), and any line following a comment which ends with \ is not executed.

While this kind of makes sense when thinking about it (i.e. the current command continues in the next line) it is counterintuitive to have this happen for comments. I have some suggestions:

  1. make the \ char not work in comments
  2. mark the following line as comment too
  3. like 1, but add some way of making multi-line comments, unless there already is one.

best regards,
Phillip

Hello, I ran into a bit of a headscratcher today when moving a commented line changed the output of my fractal formula. I eventually figured out that I had two comments, the first of which was a line ending in \ (the continuation character), and any line following a comment which ends with \ is not executed. While this kind of makes sense when thinking about it (i.e. the current command continues in the next line) it is counterintuitive to have this happen for comments. I have some suggestions: 1. make the \ char not work in comments 2. mark the following line as comment too 3. like 1, but add some way of making multi-line comments, unless there already is one. best regards, Phillip
 
0
reply

I have noticed something similar. The following does not work right:

x = sin(x)   \   ; comment
      + cos(x)

The compiler complains that \ is an invalid character.

I have noticed something similar. The following does not work right: ```` x = sin(x) \ ; comment + cos(x) ```` The compiler complains that \ is an invalid character.
 
0
reply

That last error is correct, the backslash is invalid unless at the end of a line, or in a comment.

The behavior with comments is caused by the fact that the backslash is handled at a lower level so it concatenates anything. I believe it is best to leave this just as it has always been.

That last error is correct, the backslash is invalid unless at the end of a line, or in a comment. The behavior with comments is caused by the fact that the backslash is handled at a lower level so it concatenates anything. I believe it is best to leave this just as it has always been.

Ultra Fractal author

 
0
reply

I think the behavior to consume a line of actual code when used at the end of a comment is kind of confusing tbh, but that might be just me.

Then again, this is probably an issue that won't occur very often. I have been using UF for almost two decades before I found out the hard way, I guess most people will stay in the clear.

I think the behavior to consume a line of actual code when used at the end of a comment is kind of confusing tbh, but that might be just me. Then again, this is probably an issue that won't occur very often. I have been using UF for almost two decades before I found out the hard way, I guess most people will stay in the clear.
 
0
reply

Correct, and it is possible that there are existing formulas that use this and we don't want to break them.

Correct, and it is possible that there are existing formulas that use this and we don't want to break them.

Ultra Fractal author

 
0
reply
41
views
4
replies
3
followers
live preview
Enter at least 10 characters.
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft