Old 8th May 2018, 12:27   #1
alexmitev
Junior Member
 
Join Date: Feb 2017
Posts: 19
UAC_AsUser_GetGlobalVar error

Hello,

I'm using the call
PHP Code:
!insertmacro UAC_AsUser_GetGlobalVar $LANGUAGE 
in my un.onInit function, and I get the following error:
Error: could not resolve label "_UAC_AUGOGR_OP$LANGUAGEStrCpy$LANGUAGE_F" in function "un.onInit"

Which is strange, since the same call in .onInit doesn't produce any error.
I looked into the _UAC_AsUser_GenOp macro, there is a ${_UAC_AUGOGR_ID}_F label, which somehow the compiler cannot find.
I also noticed there is a
PHP Code:
return 
instruction inside this macro, I think it's not legal inside macros, or am I missing something?

Regards,
Alex
alexmitev is offline   Reply With Quote
Old 10th May 2018, 21:46   #2
Anders
Moderator
 
Anders's Avatar
 
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 4,766
The return is there because it creates a function on the fly with labels. Any run-time instruction is valid in a macro, macros are just text replacements in the first compiler phase.

Your code compiles for me, please post a minimal but complete example that reproduces the issue...

IntOp $PostCount $PostCount + 1
Anders is offline   Reply With Quote
Reply
Go Back   Winamp & SHOUTcast Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump