matchText question

Michael Doub mikedoub at gmail.com
Thu Feb 26 08:31:04 EST 2015


Here are the numbers for the 7.0.3 and 6.7.3.   Moving in the right 
direction.

7.0.3:
Original: 440
Latest: 485

6.7.3
Original: 117
Latest: 133

I am still blown away by the difference in using repeat for each and 
repeat with.   What a great lesson that will not be forgotten.

-= Mike


On 2/25/15 8:27 PM, Michael Doub wrote:
> Whew, it is now:
>
> Original: 449
> Latest:    487      on 7.0.2 ( rc2)
>
> and
> Original: 121
> Latest:    138  on 6.6.4
>
> This is the difference between   repeat with i = 1 to whatever and 
> repeat for each line i in whatever.  Wow!
>
> -= Mike
>
>
> On 2/25/15 7:38 PM, Mike Bonner wrote:
>> Wow, thats awful.
>>
>> On Wed, Feb 25, 2015 at 5:27 PM, Michael Doub <mikedoub at gmail.com> 
>> wrote:
>>
>>> Yuck... I just tried this on 7.0.2 (rc2)
>>>
>>> Original:  11184
>>> Latest:     11321
>>>
>>>
>>> On 2/25/15 7:23 PM, Michael Doub wrote:
>>>
>>>> if any one is interested.   I did this hoping that it would speed 
>>>> up my
>>>> parsing.  As it turns out my original version was faster. The original
>>>> had 8 separate matchTexts with straight forward expresions, where 
>>>> the last
>>>> version had 2 matchtexts with expressions lots of alternatives.
>>>>
>>>> Original:  1620 millisec
>>>> Latest: 1641 millisec
>>>>
>>>> For the curious: https://www.dropbox.com/s/20j4iy4oomrr12c/Parser.
>>>> livecode?dl=0
>>>>
>>>> Thanks again for everyone's help.
>>>>
>>>> -= Mike
>>>>
>>>>
>>>>
>>>> On 2/25/15 6:52 PM, Mike Bonner wrote:
>>>>
>>>>>             "^\s*(/\*).*" \ works, if you're trying to match 
>>>>> opening /*
>>>>> comments.
>>>>> If you're trying to match lines that start with * thats a different
>>>>> story.
>>>>> \* matches asterisk.  /\* matches /*
>>>>> If you want to grab the whole comment line move the .* inside the 
>>>>> parens.
>>>>> Not sure what the "include" line you're trying to match should 
>>>>> look like
>>>>> either, something funky up there, but without seeing what you need to
>>>>> match, its hard to figure out.
>>>>>
>>>>> On Wed, Feb 25, 2015 at 4:31 PM, Mike Bonner <bonnmike at gmail.com> 
>>>>> wrote:
>>>>>
>>>>>   Hey, correct me if i'm wrong, but \w+ is a geedy word grab 
>>>>> right?  Which
>>>>>> should grab to the end if the line.. Seems like the .*+ wouldn't 
>>>>>> even be
>>>>>> necessary... Yep, just checked. Its not. The only part I can't 
>>>>>> get to
>>>>>> work
>>>>>> is the last line for /*.  Not sure what it is i'm not seeing.
>>>>>>
>>>>>> On Wed, Feb 25, 2015 at 3:53 PM, Mike Bonner <bonnmike at gmail.com>
>>>>>> wrote:
>>>>>>
>>>>>>   Yes, it was to me too. Though, I did end up breaking it down into
>>>>>>> singles
>>>>>>> and they all behaved the same, which made it easier to take a WAG.
>>>>>>> Less
>>>>>>> wild than it would have otherwise been. Find the thing that's 
>>>>>>> the same
>>>>>>> for
>>>>>>> each part, and decide if its broke.
>>>>>>>
>>>>>>> On Wed, Feb 25, 2015 at 2:50 PM, stephen barncard <
>>>>>>> stephenREVOLUTION2 at barncard.com> wrote:
>>>>>>>
>>>>>>>   On Wed, Feb 25, 2015 at 12:29 PM, Mike Bonner 
>>>>>>> <bonnmike at gmail.com>
>>>>>>>> wrote:
>>>>>>>>
>>>>>>>>   Try this instead..
>>>>>>>>>       put "(?i)^\s*(\-\-\s+begin)\s+(\w+).*+|" & \
>>>>>>>>>            "^\s*(on)\s+(\w+).*+|" & \
>>>>>>>>>            "^\s*(function)\s+(\w+).*+|" & \
>>>>>>>>>            "^\s*(command)\s+(\w+).*+|" & \
>>>>>>>>>            "^\s*(private\s+function)\s+(\w+).*+|" & \
>>>>>>>>>            "^\s*(private\s+command)\s+(\w+).*+|" & \
>>>>>>>>>            "^\s*(\/\*\s+include).*+|" &  \
>>>>>>>>>             "^\s*(\*\/).*+" \
>>>>>>>>>            into expr
>>>>>>>>>
>>>>>>>>>   breaking down and displaying complex REGEX this way is very 
>>>>>>>>> helpful.
>>>>>>>> *--*
>>>>>>>> *Stephen Barncard - San Francisco Ca. USA - Deeds Not Words*
>>>>>>>> _______________________________________________
>>>>>>>> use-livecode mailing list
>>>>>>>> use-livecode at lists.runrev.com
>>>>>>>> Please visit this url to subscribe, unsubscribe and manage your
>>>>>>>> subscription preferences:
>>>>>>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>>>>>>>
>>>>>>>>
>>>>>>>   _______________________________________________
>>>>> use-livecode mailing list
>>>>> use-livecode at lists.runrev.com
>>>>> Please visit this url to subscribe, unsubscribe and manage your
>>>>> subscription preferences:
>>>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>>>>
>>>>>
>>> _______________________________________________
>>> use-livecode mailing list
>>> use-livecode at lists.runrev.com
>>> Please visit this url to subscribe, unsubscribe and manage your
>>> subscription preferences:
>>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>>
>> _______________________________________________
>> use-livecode mailing list
>> use-livecode at lists.runrev.com
>> Please visit this url to subscribe, unsubscribe and manage your 
>> subscription preferences:
>> http://lists.runrev.com/mailman/listinfo/use-livecode
>>
>





More information about the use-livecode mailing list