FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Search found 4 matches
Forum Index
Author Message
  Topic: Overloading =
jaker49

Replies: 4
Views: 16274

PostForum: General   Posted: Mon Jun 22, 2009 5:59 am   Subject: Overloading =
That was easy. Thank you.

Is there an equivalent to overloading operator<< (ostream & ).

In C++ it is

friend ostream & operator<<( ostream & os, const MyClass & M ...
  Topic: Overloading =
jaker49

Replies: 4
Views: 16274

PostForum: General   Posted: Sun Jun 21, 2009 5:39 am   Subject: Overloading =
In C++ it is possible to define the = operator

MyClass & MyClass::operator=( const MyClass& m ) {
MyData = m.MyData;
return *this;
}

Is there an equivalent in D?
  Topic: Dynamic Allocation of Rectangular Arrays
jaker49

Replies: 2
Views: 13213

PostForum: General   Posted: Sat Jun 20, 2009 2:37 pm   Subject: Dynamic Allocation of Rectangular Arrays
That's exactly what I needed. Thanks.
  Topic: Dynamic Allocation of Rectangular Arrays
jaker49

Replies: 2
Views: 13213

PostForum: General   Posted: Fri Jun 19, 2009 4:22 pm   Subject: Dynamic Allocation of Rectangular Arrays
Howdy y'all. I'm new to D (coming from C++, Python, and Oberon).

The D doc says we can do this;
float [] [] matrix;

But it doesn't say how to dynamically allocate. How do I allocate for a 3x4 ...
 
Page 1 of 1
All times are GMT - 6 Hours
Jump to:  


Powered by phpBB © 2001, 2005 phpBB Group