#1 2018-07-12 19:31:40

xiwuping
Member
Registered: 2018-02-11
Posts: 32

W1032 Exported package threadvar 'mORMot.ServiceContext' cannot be use

When rebuild mORMot as a bpl,  I had this warning:
[dcc64 Warning]  W1032 Exported package threadvar 'mORMot.ServiceContext' cannot be used outside of this package

Should ignore this?

Offline

#2 2018-07-13 12:38:56

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,670
Website

Re: W1032 Exported package threadvar 'mORMot.ServiceContext' cannot be use

No please check https://synopse.info/files/html/Synopse … #TITLE_410

Documentation wrote:

If your code is compiled within some packages, threadvar read won't work, due to a Delphi compiler/RTL restriction (bug?). In such case, you have to call the following function instead of directly access the threadvar:

 function CurrentServiceContext: TServiceRunningContext;

Offline

Board footer

Powered by FluxBB