Filehost.ro - gazduire fisiere
lisp2arx
Visual Programming for AutoLisp Mathématiques en programmation Lisp.. doc2cpp,doc2lsp, sld2lsp, bmp2dcl, free__GifCcapture for all-CAD'platforms..
Nou pe simpatie:
ro_xy20 la Simpatie.ro
Femeie
24 ani
Bucuresti
cauta Barbat
24 - 45 ani
lisp2arxReguliInregistrareLoginPozeNu sunteti logat. Lista Forumurilor Pe Tematici
lisp2arx / Delphi , InnoPascal /

Delphi32- Fast compare kNsiConditionStrings

Pagini: 1  
#1
admin
Administrator
Din: Bucharest
Postari: 523
Which is fastest of compare-strings {Main#1} or {Main#2)?
I need the fastest compare.str  inside your compiler.

Code:

Begin {Main#1}
           if (length(a172)>0) then cc1:=locase(a172[1]) else cc1:=#0;
           if (cc1='a') and ((a172='acor') or (a172='acsetq')  or (a172='acprogn') or
       (a172='acrepeat') or (a172='acwhile') or (a172='acsetq')) then exit;

End;

function tefuncs_js:integer; 
Begin tok:=a172;php_create_function(2);
      result:=RTNORM;
   End;

Code:

{--}
Begin {Main#2}
           if (length(a172)>0) then cc1:=locase(a172[1]) else cc1:=#0;
           if (cc1='a') then 
              case (length(a172)) of 
                4: if (a172='acor') then exit;
                5: if (a172='acand') then exit;
                6: if (a172='acsetq') then exit;
                7: if ((a172='acprogn')or(a172='acwhile')) then exit;
                8: if (a172='acrepeat') then exit;
             End;
{--}
           if (cc1='a')and(a172='acxor') 
              then begin tok:='(boole 6 ';php_create_function(0);exit;end;
End;
{--}

Searching string in largeString

Code:

Begin {Main#3}
            if (length(a172)>0) then cc1:=locase(a172[1]) else cc1:=#0;
            if (cc1='a') and (pos(','+a172+',',acor,acand,acsetq,acprogn,acrepeat,')>0) 
                        then exit;
End;



_______________________________________
http://www.puiubrat.3x.ro/lisp2arx/lisp ... O2UTM2.pdf

 
   

Topicuri similare

Pagini: 1  
Mergi la