Community
    • Login

    Need Help in "Define your language" section

    Scheduled Pinned Locked Moved Help wanted · · · – – – · · ·
    2 Posts 2 Posters 1.8k Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Anand MohanA Offline
      Anand Mohan
      last edited by

      Hi,

      I’m Adding PL1/PLI language to Npp, in that i need to add the folding for proc statements

      Example code will be like

      abc; PROC;
      statement 1;
      statement 2;
      statement 3;
      end abc;

      the statement 1,2 and 3 may contain “END;” as a statement, so i cannot use "END"as the end-of-fold

      So i need a folding for

      ***; proc;
      statement 1;
      statement 2;
      statement 3;
      end; ***;

      *** can be anything which is procedure name…

      1 Reply Last reply Reply Quote 0
      • Jim DaileyJ Offline
        Jim Dailey
        last edited by

        @Anand-Mohan

        I don’t know PL1, but if it has any type of preprocessing ability like C does, you could do something like this:

        #define procend end
        

        and then use “procend” in your code. This is not ideal, I admit.

        Otherwise, I think you have to define all the statement N’s you might use as the beginning of some fold (Open:) and add the corresponding number of “end” statements to end the fold (Close:). That is, you can have multiple Open:, Middle: and Close: tokens; just make sure they are in the correct order (first Close: goes with the first Open:, etc.).

        1 Reply Last reply Reply Quote 0

        Hello! It looks like you're interested in this conversation, but you don't have an account yet.

        Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

        With your input, this post could be even better 💗

        Register Login
        • First post
          Last post
        The Community of users of the Notepad++ text editor.
        Powered by NodeBB | Contributors