Re: VC10 and out_value policy compile issues

Felipe Magno de Almeida <[email protected]>
Newsgroups gmane.comp.lang.lua.bind.user
Message-ID <[email protected]>
On Mon, Apr 4, 2011 at 7:21 AM, Felipe Magno de Almeida
<[email protected]> wrote:
> On Mon, Jul 12, 2010 at 8:33 AM,  <[email protected]> wrote:
>> Thx Max,
>>
>> You are correct, I had a _2 before, and just changed to the _3 to make
>> sure I wasn't over looking something and forgot to change that back. I
>> found a work around for now but I'm still getting the error on compiling
>> in VS 2010. This may be some quirky problem with 2010 I'm not sure, as
>> soon as I find the solution I will post it up here.
>
>
> I'm having the exact same problem. It works fine with primitives, but
> std::string fails when using pure_out_value. What is your workaround
> for pure_out_value in VS 2010?

I found out one way to make it compile. The problem seems to be that
VS 2010 isn't able to instantiate identity in this context:

template<class U>
char_array<sizeof(typename identity<U>::type)>
indirect_sizeof_test(by_reference<U>);

With any of the overloads. There's a workaround just above this to
deal with GCC 3.1 (I think) where it doesn't use identity, but U
directly. I added MSVC with MSC_VER == 1600 and it worked.

> [snip]
> --
> Felipe Magno de Almeida
>



-- 
Felipe Magno de Almeida

------------------------------------------------------------------------------
Xperia(TM) PLAY
It's a major breakthrough. An authentic gaming
smartphone on the nation's most reliable network.
And it wants your games.
http://p.sf.net/sfu/verizon-sfdev
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.