Re: [eigen] Re: leftCol(0) |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/eigen Archives
]
- To: eigen@xxxxxxxxxxxxxxxxxxx
- Subject: Re: [eigen] Re: leftCol(0)
- From: Benoit Jacob <jacob.benoit.1@xxxxxxxxx>
- Date: Sat, 26 Jun 2010 08:33:09 -0400
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=G6ulfsVQ4kR/hHSzULK5v00k9MRh1DewOsbjTeAHOJM=; b=qk3Em516gH6aeZgwMVjrdG+KXuC0UH8gQHwNmB07eJUHyplnwkQZ7YI2Qr2KKh9gEB cSZ8GBewzQNaHQ0L7e1bHAt568VZXFOG67Z1ieOIzuEIIwwXA83/A/WcRkJBWzwNK4c8 xR3WBpeXCokFM1WKHJQBvxfcejPenit7H+VOw=
- 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=v2h8ikZ5mFDSXesb2mqk6iPuHp4ErxAf7rgyl85gTcGsyjzADUl/CWEdeQkftfSyJ1 ezJuIT3/vlLFrXuZ581xV5BzL9KMvrVPgh2iI5hS4o4tYsLn8Q3j9EVLntcW00nC7UaU JAG4EWTV4a+IMNvFQzd4q+ZFA+twy93ktcLlM=
Both versions should have the effect of printing anything, but they
should be allowed (we try to allow zero sizes for convenience)
Can you file a bug on the tracker? No time now to fix it.
Benoit
2010/6/26 Carlos Becker <carlosbecker@xxxxxxxxx>:
> Another remark: doing std::cout << m.leftCols<0>() << std::endl; ends up in
> a segfault at compile time.
>
>
> On Sat, Jun 26, 2010 at 12:25 PM, Carlos Becker <carlosbecker@xxxxxxxxx>
> wrote:
>>
>> Hi everyone.
>> I was trying some code while writing the Block operations tutorial and
>> found that the output of the following program does not make much sense:
>> #include <Eigen/Dense>
>> #include <iostream>
>>
>> using namespace Eigen;
>>
>> int main()
>> {
>> Matrix<float,3,3> m;
>> m << 1,2,3,
>> 4,5,6,
>> 7,8,9;
>>
>> std::cout << m.leftCols(0) << std::endl;
>>
>> return 0;
>> }
>> I wonder if this is a desired behaviour. I was expecting to get a
>> compile-time error, or at least a run-time one.
>> Carlos
>