Range Commenting

Posted 8 years ago by Avatar Samuel Amoser

Within SyntaxEditor, the range commenting can't be nested. This behaviour is well known from different programming languages.
/*comment /*comment*/ no comment*/
Would it be possible to allow nested range comments, as shown below?
/*comment /*comment*/ still a comment*/

Comments (2)

Posted 8 years ago by Actipro Software Support - Cleveland, OH, USA

Are you using a dynamic lexer? If so, you should be able to achieve that if you have your comment state transition to itself as a child state. You'd have to make sure your tokens in the comment state break on / chars (they already should be breaking on * chars) so that the child state start scope can be recognized.

Also set the scope's AncestorEndScopeCheckEnabled property to false. Doing those things should get it working.

Actipro Software Support
Posted 8 years ago by Samuel Amoser
We are still in evaluation. But as it should be possible, it's great. Thanks.

Information The latest build of this product (2017.2 build 0665) was released 1 month ago, which was after the last post in this thread.

Add a Comment

Please log in to a validated account to post comments.