Tapatalk

Function strings with A OR B OR C ?

Function strings with A OR B OR C ?

7
NewbieNewbie
7

    Mar 25, 2006#1

    Hi all,
    I want to do a regular expression that find any one of 3 words.

    Specifically, I want to find:
    Property, Sub or Function

    This is so I can have the function list include the Property functions of a class

    In my wordfile, I currently have:

    /Function String = "^{Sub^}^{Function^} [',a-z,A-Z,0-9,_, ,(,)]+$"

    The best I've been able to do on my own is:
    /Function String = "%[ ^t]++[FPS][ur][nobi][a-z]++ [',a-z,A-Z,0-9,_, ,(,)]+$"

    besides being extremely obscure, I must include a comment after every private variable declaration with an illegal character in it (I use =) so those variable declarations don't get confused w/ comments


    Is there any way to do something akin to:
    "^{Sub^}^{Function^} ^{Property^}

    Regards,
    Vorpal

    119
    Power UserPower User
    119

      Mar 25, 2006#2

      You can define up to six function strings in the wordfile.

      Code: Select all

      /Function String = ...
      /Function String 1 = ...
      ...
      /Function String 5 = ...
      Unless you've already used the other five, it would be simplest (and clearest) to define multiple rules instead of forcing everything into one.