- Initialize a static const matrix - 2 Updates
- The Problem with Christianity - 4 Updates
- Free Webinar: C++ Boot Camp - 1 Update
Mark <ma740988@gmail.com>: Jul 31 10:26AM -0700 Consider: # include <iostream> # include <cstring > template < size_t Rows, size_t Cols, typename ElemType = double > class TestMatrix { public : ElemType elems[Rows ] [ Cols ]; //ElemType elems[Rows * Cols ]; }; class Foo { static const TestMatrix < 2, 2 > test ; static const unsigned int val[2][2]; // Specify all dimensions. public : Foo () ; }; Foo::Foo() { } // works C style for multi-dimensional const unsigned int Foo::val[][2] = { { 0, 1 } , { 2, 3 } }; const TestMatrix < 2, 2 > Foo::test = { { 0.1, 1.1 } , { 2.2, 3.2 } }; int main() { } The compiler I'm using has no C++11 support, that said, how can I initialize the static const test member within Foo? Unclear why the initialization of test fails when the TestMatrix effectively mimics the c-style approach to a multi-dimensional array Thanks in advance |
red floyd <no.spam.here@its.invalid>: Jul 31 01:34PM -0700 On 7/31/2016 10:26 AM, Mark wrote: > } > The compiler I'm using has no C++11 support, that said, how can I initialize the static const test member within Foo? Unclear why the initialization of test fails when the TestMatrix effectively mimics the c-style approach to a multi-dimensional array > Thanks in advance If all you have is C++03 support, then provide a constructor that takes an N by M array |
"Rick C. Hodgin" <rick.c.hodgin@gmail.com>: Jul 31 04:03AM -0700 On Saturday, July 30, 2016 at 12:29:04 PM UTC-4, JiiPee wrote: > > not appropriate. > Even though am a christian, i kind of agree that C++ forum is not a > place to start religious arguments :) I don't argue or debate with people. I teach them. I teach the truth about sin, their nature, eternity and eternal life, and their need for a savior (Jesus Christ) to pay the price of their sin for them, so that they are set free from the punishment of sin. Best regards, Rick C. Hodgin |
"Rick C. Hodgin" <rick.c.hodgin@gmail.com>: Jul 31 04:06AM -0700 On Saturday, July 30, 2016 at 10:39:06 AM UTC-4, Öö Tiib wrote: > If there is God then He will not thank you for that imago. There is a God. Jesus Christ is God in the flesh. Why flesh when we can't see God? Because He came here to save us. He came to here to give us a way out of the punishment required by God for sin. Jesus told us the world would hate us. He told us that they would kill us even. It's no surprise that many are offended by the gospel message because many people are not going to be saved (because they will not be saved). Best regards, Rick C. Hodgin |
"Öö Tiib" <ootiib@hot.ee>: Jul 31 09:42AM -0700 On Sunday, 31 July 2016 14:07:06 UTC+3, Rick C. Hodgin wrote: > On Saturday, July 30, 2016 at 10:39:06 AM UTC-4, Öö Tiib wrote: > > If there is God then He will not thank you for that imago. > There is a God. Ok, then be prepared to meet His endless forgiveness for being such an arse of a person. > Jesus told us the world would hate us. He told us that they would kill us > even. It's no surprise that many are offended by the gospel message because > many people are not going to be saved (because they will not be saved). You misunderstood John 15. May be you did not even read it. Lot of idiots like you are too impatient to read the Book. They think it is like license agreement, scroll to end and press yes and you are forgiven and in heaven. Jesus told in John 15 that people will hate you because they hate Him and His Father. That may well be. However on current case you make people to hate you because of being annoying self-centered asshole. That has nothing to do with Jesus. That wasn't what Jesus suggested you to be at first place. |
"Öö Tiib" <ootiib@hot.ee>: Jul 31 09:45AM -0700 On Sunday, 31 July 2016 14:03:40 UTC+3, Rick C. Hodgin wrote: > > Even though am a christian, i kind of agree that C++ forum is not a > > place to start religious arguments :) > I don't argue or debate with people. I teach them. No, you annoy people. We try to forgive you that sin because we understand that you are self-centered idiot and can't help yourself. |
Good Guy <hello.world@example.com>: Jul 31 04:31AM +0100 Some of you here would benefit from attending this webinar: <http://community.embarcadero.com/blogs?view=entry&id=8637> All the experts are there to answer all your questions and you can also get a free license <https://www.embarcadero.com/app-development-tools-store/cbuilder> for your own copy of C++ Builder. -- With over 350 million devices now running Windows 10, customer satisfaction is higher than any previous version of windows. |
You received this digest because you're subscribed to updates for this group. You can change your settings on the group membership page. To unsubscribe from this group and stop receiving emails from it send an email to comp.lang.c+++unsubscribe@googlegroups.com. |