Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Trigger: Process
#6
function'str arguments
...
ret local str var


But it is dangerous. When you assign the function to a str variable, then OK. But if you assign it to a lpstr variable or function argument, the lpstr will be invalid. Same with sel.

Or can be

function'lpstr arguments
...
ret thread-local str variable

Then you can assign it to str, lpstr, sel, etc. The string becomes invalid when the thread exits or the function called again, but it is usually already not used then.

For these reasons it is better to use str& argument instead.


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)