|
newbie question: msg#00299lang.erlang.general
Hi I have a question regarding performance! I have a module (test) with a record test defined .i.e %%%%%%%%%%%%%%%%%%%%%%%%%%% -module(test). -record( test, { field1, field2, field3}). -export([ compare/2 ]). -compare( A, B ) when record(A, test), record(B, test) -> case A#test.field1 > B#test.field1 of true -> "A>B"; false -> "A/>B" end. %%%%%%%%%%%%%%%%%%%%%%%%%%% The reuse of 'test' as module name and record name helps reduce the number of atoms used, but would this have an impact if any on performance when more complex calculations are done? NOTE: This e-mail message is subject to the MTN Group disclaimer see http://www.mtn.co.za/email_disclaimer.asp |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | parser & scanner: 00299, Vlad Dumitrescu |
|---|---|
| Next by Date: | guards: 00299, Vlad Dumitrescu |
| Previous by Thread: | parser & scanneri: 00299, Vlad Dumitrescu |
| Next by Thread: | Re: newbie question: 00299, Ulf Wiger |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |