Re: [eigen] CoeffReturnType causing lots of warning on vs2008 |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/eigen Archives
]
- To: eigen@xxxxxxxxxxxxxxxxxxx
- Subject: Re: [eigen] CoeffReturnType causing lots of warning on vs2008
- From: Benoit Jacob <jacob.benoit.1@xxxxxxxxx>
- Date: Fri, 3 Apr 2009 20:12:14 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=TfXabRDqkPfJbhdzx28dxviZjoD1VcBUhE3YE3XR35M=; b=NLtOz+a875lE8jzFRm7PI181i9jHoWX7zU5RxG/CSn1ChhF1RcUF5mAfwo00cxAdAW wUOrIfcnJMd0nElAKtIZY4+wn+OZ025aHDpSvY589tS61L5tCVKG8z4JJnAeqzkzUOMB Mv4Iua4ps9tXA9aVwrDGZV3UyUMYQosVvHREU=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=FKTj5xv2zN28jAZse6C6CLZJ/EgnIUJA0l8UcjSQ2IHKlvrc1+hyOD2nXi8ongXMII fM/NPGAmN396V6TlcP2+sBuxJX1w0vM8JLcRO/ssz4NkPYeQz3hOFlilsXHKpfjCHcEJ b6dPbtoMZET1HAVSQ/bhxKYbyyEcoui+eHjXE=
Hi Kenneth,
can you try the following : go to MatrixBase.h line 204:
typedef typename ei_meta_if<int(Flags)&DirectAccessBit, const
Scalar&, Scalar>::ret CoeffReturnType;
the idea is that presumably MSVC makes the bitwise & return an
unsigned int, and then doesn't like the implicit cast to bool when
using that as the first template param to ei_meta_if<...>.
So you could try changing this line like this:
typedef typename ei_meta_if<bool(int(Flags)&DirectAccessBit),
const Scalar&, Scalar>::ret CoeffReturnType;
If you get something that looks reasonable and fixes your issue, don't
hesitate to commit !
Benoit
2009/4/3 Kenneth Riddile <kfriddile@xxxxxxxxx>:
> I just updated to the latest trunk after being out of the loop for awhile,
> and I'm getting warnings similar to http://pastebin.com/m1ba91b7e everywhere
> I instantiate something like:
> typedef float Real;
> Eigen::Matrix<Real, 4, 4> matrix;