Indeed code below works,
```
import std.stdio: write,writeln;
class Node {
int data;
Node next;
}
class List {
Node node=null;
this(int[] AR){foreach(i ; AR)pushfront(i);}
void pushfront(int data) {
Node newnode=new Node();
On Monday, 25 April 2022 at 01:40:01 UTC, Alain De Vod wrote:
Following program is a single linked list.
We expect as output 1 2 3 1 2 3
But the output is only 1 2 3
```
If you don't need List to be treated as a true range, but just
want to iterate, a simple way to do this is with opApply
On 4/25/22 03:48, Salih Dincer wrote:
> It is also possible with the copy constructor of a struct. I don't know
> how to do with class...
Classes don't have language provided construction because nobody needs
it and in fact they have to protect themselves when a language provides
it. (See,
On Monday, 25 April 2022 at 09:38:05 UTC, Alain De Vos wrote:
This program works ok, (but List is no Range)
It is also possible with the copy constructor of a struct. I
don't know how to do with class...
```d
struct Node {
int element;
Node * next;
}
This program works ok, (but List is no Range)
```
class Node {
int data;
Node next;
}
class List {
Node node=null;
this(int[] AR){foreach(i ; AR)pushfront(i);}
bool empty() const {return !node;}
void popFront() {node=node.next;}
float
On Monday, 25 April 2022 at 05:17:28 UTC, Salih Dincer wrote:
On Monday, 25 April 2022 at 02:19:46 UTC, Ali Çehreli wrote:
This type violates a fundamental rule: Containers and ranges
are separate concepts. Your List is a container, not a range.
I changed your code by moving the range
On Monday, 25 April 2022 at 02:19:46 UTC, Ali Çehreli wrote:
This type violates a fundamental rule: Containers and ranges
are separate concepts. Your List is a container, not a range. I
changed your code by moving the range functions to a Range [...]
Dear Ali,
I implemented a linkedlist
On 4/24/22 18:40, Alain De Vod wrote:
> I think this has something to do with popFront
This type violates a fundamental rule: Containers and ranges are
separate concepts. Your List is a container, not a range. I changed your
code by moving the range functions to a Range struct that is created
Following program is a single linked list.
We expect as output 1 2 3 1 2 3
But the output is only 1 2 3
I think this has something to do with popFront
How to fix it using "class List" ?
```
import std.stdio: write,writeln;
import std.range: empty,popFront,front;
struct Node {
Here a working code,
```
import std.stdio;
void main(){
struct List {
struct Node {
float f;
Node *next=null;
}
Node * root=null;
bool empty() const {return !root;}
void popFront() {root=root.next;}
float front()
21.04.2021 16:19, Alain De Vos пишет:
import std.stdio;
void main(){
struct List {
struct Node {
float f;
Node *next;
}
Node * root=null;
bool empty() const {return !root;}
void popFront() {root=root.next;}
Formatted ,
```
import std.stdio;
void main(){
struct List {
struct Node {
float f;
Node *next;
}
Node * root=null;
bool empty() const {return !root;}
I try to create manually and explicit an interetable single
linked list of floats. Probably one of the most basic
datastructures.
import std.stdio;
void main(){
struct List {
struct Node {
float f;
Node *next
On Thursday, 29 October 2020 at 22:02:52 UTC, Paul Backus wrote:
I'm pretty sure the post you replied to is spam.
Yes, when I read the post again it is kind of hollow.
On Thursday, 29 October 2020 at 18:10:28 UTC, IGotD- wrote:
Is this what you are looking for?
https://dlang.org/phobos/std_container_dlist.html
I'm pretty sure the post you replied to is spam.
On Thursday, 29 October 2020 at 18:06:55 UTC, xpaceeight wrote:
https://forum.dlang.org/post/bpixuevxzzltiybdr...@forum.dlang.org
It contains the data and a pointer to the next and previous
linked list node. This is given as follows. struct Node { int
data; struct Node *prev; struct Node
https://forum.dlang.org/post/bpixuevxzzltiybdr...@forum.dlang.org
It contains the data and a pointer to the next and previous
linked list node. This is given as follows. struct Node { int
data; struct Node *prev; struct Node *next; }; The function
insert() inserts the data into the beginning
On Tuesday, 28 January 2020 at 20:20:25 UTC, Barry allen wrote:
your linked list seems very complex https://get-shareit.com
https://get-vidmateapk.com
/* Node of a doubly linked list */
struct Node {
int data;
struct Node* next; // Pointer to next node in DLL
struct Node
your linked list seems very complex
On Saturday, 28 September 2019 at 16:21:10 UTC, snow jhon wrote:
On Saturday, 21 September 2019 at 18:52:23 UTC, Dennis wrote:
[...]
Below is a simple doubly linked list with Garbage Collected
memory.
It's not performant or complete by any means, just a minimal
example in D like you wanted
becomes
std.container.dlist.
Does a doubly-linked list always have to be done with structs?
Can it be classes instead?
My example originally included classes actually. It was mostly
the same, except that Node!T* was just Node!T. The only problem
was with const:
```
size_t length() const
On Monday, 23 September 2019 at 22:40:41 UTC, Ali Çehreli wrote:
So, what was it then? Append to an array, sort it, and be
happy? :)
Ali
Hi, Ali,
It turns out that the GTK Notebook has its own built-in mechanism
for tracking tabs. Two things got me going down the wrong road on
this:
1)
On 09/23/2019 01:45 PM, Ron Tarrant wrote:
> Well, it turns out, I didn't need a linked list, doubly or otherwise.
So, what was it then? Append to an array, sort it, and be happy? :)
Ali
Well, it turns out, I didn't need a linked list, doubly or
otherwise. That's what happens when a person quits coffee for a
week: complete brain chaos.
For a full week, I banged on this, trying to work out a scheme
whereby I could track GTK Notebook tabs with a doubly-linked
list, an array
k with, whereas nodes
in a linked list are normally private to the list, so it's easy to ensure
that they're only ever on the heap even if they're structs).
- Jonathan M Davis
Sorry. I posted the wrong file. This is the one that works:
```
import std.stdio;
import std.conv;
class TabList
{
private:
Tab _head;
int _lastUniqueID = 0;
string labelText;
this()
{
append();
}
becomes
std.container.dlist.
Does a doubly-linked list always have to be done with structs?
Can it be classes instead?
My example originally included classes actually. It was mostly
the same, except that Node!T* was just Node!T. The only problem
was with const:
```
size_t length() const
implementation not
optimized for speed / memory efficiency.
Making it 'complete' is a bit hard since I can think of tens of
methods and operator overloads you could use, but if I include
them all it's no longer minimal and it just becomes
std.container.dlist.
Does a doubly-linked list always
Thanks for all the responses, y'all.
I got it figured out thanks to ag0aep6g pointing out something I
forgot about the nature of class objects in D (Damn my failing
memory). The results will show up on the gtkDcoding blog sometime
in (I'm guessing) November as part of the the Notebook
On Friday, 20 September 2019 at 20:26:03 UTC, Ron Tarrant wrote:
Hi guys,
I've been banging my head on the screen with this one for the
last week or so. For whatever reason, I'm having major problems
understanding how to implement a doubly-linked list in D. I
don't know if it's because I'm
On Saturday, 21 September 2019 at 09:03:13 UTC, Ron Tarrant wrote:
Ah! Thanks, ag0aep6g. I was wondering about that when I was
writing the code. (If I already knew this, I'd forgotten.) I
did as you suggested, took out all '*' and '&' and it works
perfectly.
Is this what you want?
---
On Saturday, 21 September 2019 at 08:49:48 UTC, ag0aep6g wrote:
On 21.09.19 10:34, Ron Tarrant wrote:
Here's a question for the room:
Does a doubly-linked list always have to be done with structs?
Can it be classes instead? (Maybe that's why I can't get it to
work, because I've been trying
On 21.09.19 10:34, Ron Tarrant wrote:
Here's a question for the room:
Does a doubly-linked list always have to be done with structs? Can it be
classes instead? (Maybe that's why I can't get it to work, because I've
been trying to make an OOP version?)
It can be done with classes.
When I
On Friday, 20 September 2019 at 20:35:41 UTC, H. S. Teoh wrote:
Not a minimal example by any means, but Phobos *does* come with
a doubly-linked list implementation: std.container.dlist.
Thanks, H.S. I did come across that in my search. Trouble is,
with all the extra stuff in there, I'm
On Friday, 20 September 2019 at 20:26:03 UTC, Ron Tarrant wrote:
If someone could please post a minimal example (if there's
extra stuff in there, I'll get confused; I'm getting that old,
dammit) I'd be ever so grateful.
Below is a simple doubly linked list with Garbage Collected
memory.
It's
On Fri, Sep 20, 2019 at 08:26:03PM +, Ron Tarrant via Digitalmars-d-learn
wrote:
> Hi guys,
>
> I've been banging my head on the screen with this one for the last
> week or so. For whatever reason, I'm having major problems
> understanding how to implement a doubly-linked lis
Hi guys,
I've been banging my head on the screen with this one for the
last week or so. For whatever reason, I'm having major problems
understanding how to implement a doubly-linked list in D. I don't
know if it's because I'm losing my ability to sort these things
or if it's just
; and then iterate the array and repair the next/prev
pointers.
If possible, I would go further and ditch the linked list
altogether: Just append the nodes to an array and then sort the
array. It has been shown in research, conference presentations,
and in personal code to be the fasted op
On 08/13/2019 03:12 PM, Mirjam Akkersdijk wrote:
> For the application I am writing, it makes very much sense to use a DLL.
Yes, Dynamically Linked Libraries can be useful. Oh wait... You mean
Doubly-Linked List. :o)
> I tried setting the length first and iterating through it with `n
On Tuesday, 13 August 2019 at 22:12:23 UTC, Mirjam Akkersdijk
wrote:
Though, it left me with some semi-offtopic questions unanswered:
(1) Ali, do you mean that from an optimization viewpoint, it's
better to keep appending like `nodes ~= ...` instead of setting
the length first? I would like
application and create an array
just for sorting operations. No new nodes are added and no nodes
are permanently removed.
You can still get a cache-efficient linked list by chunking.
[...]
I very much appreciate this thought, as I was thinking of adding
such kind of cache to my implementation. It's
e null for pointers. (If we are back
to linked list Node pointers.)
However, I wouldn't bother with setting length either as the
cost of automatic array resizing is amortized, meaning that it
won't hurt the O(1) algorithmic complexity in the general case.
In the GC case that D uses, it will be even
std::vector was a lot faster than a linked list for all supported
> operations. I don't know how clever the caching strategies are on a
> modern processor (Pointer chasing), but to my knowledge the only way
> of getting a cache efficient linked list would be to effectively have
> a very con
On Tuesday, 13 August 2019 at 18:54:58 UTC, H. S. Teoh wrote:
On Tue, Aug 13, 2019 at 11:28:35AM -0700, Ali Çehreli via
Digitalmars-d-learn wrote: [...]
Summary: Ditch the linked list and put the elements into an
array. :)
[...]
+1. The linked list may have been faster 20 years ago, before
v pointers.
If possible, I would go further and ditch the linked list
altogether: Just append the nodes to an array and then sort the
array. It has been shown in research, conference presentations,
and in personal code to be the fasted option is most (or all)
cases.
Yeah, very like
On Tue, Aug 13, 2019 at 11:28:35AM -0700, Ali Çehreli via Digitalmars-d-learn
wrote:
[...]
> Summary: Ditch the linked list and put the elements into an array. :)
[...]
+1. The linked list may have been faster 20 years ago, before the
advent of modern CPUs with caching hierarchies and mem
rs.
If possible, I would go further and ditch the linked list altogether:
Just append the nodes to an array and then sort the array. It has been
shown in research, conference presentations, and in personal code to be
the fasted option is most (or all) cases.
> doesn't the nature of the dynamic arr
On Tue, Aug 13, 2019 at 12:12:28PM -0600, Jonathan M Davis via
Digitalmars-d-learn wrote:
> On Tuesday, August 13, 2019 11:33:10 AM MDT Mirjam Akkersdijk via
> Digitalmars-d-learn wrote:
[...]
> > Thank you, this is what I eventually chose to do. It's also fairly
> > fast, though doesn't the
Am 13.08.19 um 11:48 schrieb Mirjam Akkersdijk:
> Hello there,
> If I had a DLL, how would I sort it judging by the node contents, the D
> way?
>
> In C if I were to sort a piece of malloc'd memory pointing to node
> pointers, I would write my compare function and let qsort sort it out.
> In D, I
On Tuesday, August 13, 2019 11:33:10 AM MDT Mirjam Akkersdijk via
Digitalmars-d-learn wrote:
> On Tuesday, 13 August 2019 at 14:04:45 UTC, Sebastiaan Koppe
>
> wrote:
> > On Tuesday, 13 August 2019 at 09:48:52 UTC, Mirjam Akkersdijk
> >
> > wrote:
> >> and I would like to sort based on Node.t,
On Tuesday, 13 August 2019 at 14:04:45 UTC, Sebastiaan Koppe
wrote:
On Tuesday, 13 August 2019 at 09:48:52 UTC, Mirjam Akkersdijk
wrote:
and I would like to sort based on Node.t, how should I tackle
it, preferably without resorting to C libraries?
Convert the nodes into an D array, sort the
On Tuesday, 13 August 2019 at 12:34:46 UTC, bachmeier wrote:
I'm confused by this statement. Are you referring to the qsort
in C's stdlib? I had never heard of using that to sort a linked
list, so I searched, and it is not possible.
Ah yes, maybe I should have elaborated. In C, you can just
On Tuesday, 13 August 2019 at 09:48:52 UTC, Mirjam Akkersdijk
wrote:
and I would like to sort based on Node.t, how should I tackle
it, preferably without resorting to C libraries?
Convert the nodes into an D array, sort the array with
nodes.sort!"a.x < b.x" and then iterate the array and
On Tuesday, 13 August 2019 at 09:48:52 UTC, Mirjam Akkersdijk
wrote:
I would write my compare function and let qsort sort it out.
I'm confused by this statement. Are you referring to the qsort in
C's stdlib? I had never heard of using that to sort a linked
list, so I searched
On Tuesday, 13 August 2019 at 09:48:52 UTC, Mirjam Akkersdijk
wrote:
Hello there,
If I had a DLL, how would I sort it judging by the node
contents, the D way?
In C if I were to sort a piece of malloc'd memory pointing to
node pointers, I would write my compare function and let qsort
sort it
ime. I don't know
why you would think that arrays would need to know their size at compile
time unless you've only been using static arrays. However, a doubly-linked
list definitely isn't random access, so it wouldn't work with
std.algorithm.sort, and I don't think that Phobos has anything which wo
You can make an array from it
On Tue, Aug 13, 2019 at 12:05 PM Mirjam Akkersdijk via
Digitalmars-d-learn wrote:
>
> On Tuesday, 13 August 2019 at 09:48:52 UTC, Mirjam Akkersdijk
> wrote:
> > Hello there,
> > If I had a DLL, how would I sort it judging by the node
> > contents, the D way?
> >
> >
On Tuesday, 13 August 2019 at 09:48:52 UTC, Mirjam Akkersdijk
wrote:
Hello there,
If I had a DLL, how would I sort it judging by the node
contents, the D way?
[...]
Node.t
Node.x, my bad
Hello there,
If I had a DLL, how would I sort it judging by the node contents,
the D way?
In C if I were to sort a piece of malloc'd memory pointing to
node pointers, I would write my compare function and let qsort
sort it out. In D, I tried to use std.algorithm's sort
functionality to no
On Sunday, 19 May 2019 at 22:20:48 UTC, Josh wrote:
Thank you, that helps big time.
This is just more curiosity, but do you happen to know why I
have to use DList.linearRemove() instead of DList.remove()?
import std.stdio;
import std.container.dlist;
import std.algorithm;
import std.range;
On Sunday, 19 May 2019 at 22:20:48 UTC, Josh wrote:
This is just more curiosity, but do you happen to know why I
have to use DList.linearRemove() instead of DList.remove()?
These two functions are separate because they differ in
complexity. remove is O(1), linearRemove on the other hand
Thank you, that helps big time.
This is just more curiosity, but do you happen to know why I have
to use DList.linearRemove() instead of DList.remove()?
import std.stdio;
import std.container.dlist;
import std.algorithm;
import std.range;
void main()
{
auto list = make!DList("the",
On Sunday, 19 May 2019 at 20:55:28 UTC, Josh wrote:
Just started looking at D this weekend, coming from a
C++/Java/Go/Rust background and it's really not going well.
Trying to write something to play with the language and need a
linked list, looking in std.container you have a single
Just started looking at D this weekend, coming from a
C++/Java/Go/Rust background and it's really not going well.
Trying to write something to play with the language and need a
linked list, looking in std.container you have a single or doubly
linked list...great.
Now how to I iterate over
I just started working on a project in which it would be
convenient to hold a reference to a specific entry in a DList.
The interface doesn't seem to provide a way to get a pointer to a
raw node struct, so about the best solution I can find is to get
a range out of the list, pop elements until
On Tuesday, 7 July 2015 at 09:35:12 UTC, Jonathan M Davis wrote:
This is why you almost never use @trusted on templated
functions. You should
_never_ mark anything with @trusted unless you can guarantee
that it's
actually @safe. @safe is inferred for templated functions, so
unless you're
doing
On Monday, July 06, 2015 21:58:30 anonymous via Digitalmars-d-learn wrote:
Off topic: I think `@trusted:` is horrible. It's easy to forget
that you're in a @trusted environment when editing things later.
And even worse, you're trusting everything that's passed through
template parameters.
How do you correctly implement a bidirectional range on a linked
list?
I have a linked list implementation and I've added a range
interface to it but after a while I've realized it not quite
right. The problem is when I call the save method of the forward
range interface I don't get a copy I
On Monday, 6 July 2015 at 20:50:19 UTC, Gary Willoughby wrote:
The problem is when I call the save method of the forward range
interface I don't get a copy I only get another view to the
same state. So when i remove nodes from the original list the
range becomes invalid.
This is why
On Monday, 6 July 2015 at 20:50:19 UTC, Gary Willoughby wrote:
How do you correctly implement a bidirectional range on a
linked list?
I have a linked list implementation and I've added a range
interface to it but after a while I've realized it not quite
right. The problem is when I call
On Monday, 6 July 2015 at 21:58:31 UTC, anonymous wrote:
To make your removal methods stable, it may be enough to not
free the removed node. That is, don't do this:
https://github.com/nomad-software/etcetera/blob/master/source/etcetera/collection
Looks like I messed up the URL. Here's the
On 4/3/15 6:08 PM, Kitt wrote:
On Friday, 3 April 2015 at 22:06:06 UTC, Namespace wrote:
On Friday, 3 April 2015 at 22:02:13 UTC, Kitt wrote:
Hello. I’m trying to write my own version of a list that doesn’t rely
on the garbage collector. I’m working on a very bare bones
implementation using
2. When you malloc, you use 'two.sizeof' and 'ten.sizeof'.
Integers are 4 bytes, so you were allocating 4 bytes for each
of these (not 2 or 10 bytes as is alluded to above).
Yeah, my mistake. I saw the mistake but could not describe it
correctly. :)
Namespace:
I've written a straight forward linked list implementation
here:
https://github.com/nomad-software/etcetera/blob/master/source/etcetera/collection/linkedlist.d
Even though I'm using the GC to manage memory, maybe it will
help you.
Good idea to link to some existing code. Here
On Saturday, 4 April 2015 at 09:05:03 UTC, bearophile wrote:
Namespace:
I've written a straight forward linked list implementation
here:
https://github.com/nomad-software/etcetera/blob/master/source/etcetera/collection/linkedlist.d
Even though I'm using the GC to manage memory, maybe
Hello. I’m trying to write my own version of a list that doesn’t
rely on the garbage collector. I’m working on a very bare bones
implementation using malloc and free, but I’m running into an
exception when I attempt to call free. Here is a very minimal
code sample to illustrate the issue:
//
On Friday, 3 April 2015 at 22:08:52 UTC, Kitt wrote:
Thanks for the help =) I guess I've been in C# land at work for
way too long now, my low level C skills are evaporating!
I've written a straight forward linked list implementation here:
https://github.com/nomad-software/etcetera/blob/master
On Friday, 3 April 2015 at 22:02:13 UTC, Kitt wrote:
Hello. I’m trying to write my own version of a list that
doesn’t rely on the garbage collector. I’m working on a very
bare bones implementation using malloc and free, but I’m
running into an exception when I attempt to call free. Here is
a
On Friday, 3 April 2015 at 22:06:06 UTC, Namespace wrote:
On Friday, 3 April 2015 at 22:02:13 UTC, Kitt wrote:
Hello. I’m trying to write my own version of a list that
doesn’t rely on the garbage collector. I’m working on a very
bare bones implementation using malloc and free, but I’m
running
Wow, I can't even begin to explain how red my cheeks are right
now. You're completely right; I have no idea what my head was
thinking. Sure enough, call malloc with the correct type, and
the error goes away =P
Thanks for the help =) I guess I've been in C# land at work for
way too long now,
On Friday, 3 April 2015 at 22:38:00 UTC, Gary Willoughby wrote:
On Friday, 3 April 2015 at 22:08:52 UTC, Kitt wrote:
Thanks for the help =) I guess I've been in C# land at work
for way too long now, my low level C skills are evaporating!
I've written a straight forward linked list
On Wednesday, 13 August 2014 at 19:30:53 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at 07:23:30PM +, via
Digitalmars-d-learn wrote:
On Wednesday, 13 August 2014 at 18:58:59 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at 06:31:32PM +, Gary
On Monday, 11 August 2014 at 20:02:38 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
Anyway, clearly we're not understanding each other, so let me
present
some concrete code so that we aren't just talking past each
other:
I've used your advice and implemented a range over the list as
On Wed, Aug 13, 2014 at 06:31:32PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
On Monday, 11 August 2014 at 20:02:38 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
Anyway, clearly we're not understanding each other, so let me present
some concrete code so that we aren't just talking
On Wednesday, 13 August 2014 at 18:58:59 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at 06:31:32PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
On Monday, 11 August 2014 at 20:02:38 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
Anyway, clearly we're not
On Wed, Aug 13, 2014 at 07:23:30PM +, via Digitalmars-d-learn wrote:
On Wednesday, 13 August 2014 at 18:58:59 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at 06:31:32PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
[...]
I've used your advice and implemented
On Wednesday, 13 August 2014 at 18:58:59 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at 06:31:32PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
On Monday, 11 August 2014 at 20:02:38 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
Anyway, clearly we're not
On Wed, Aug 13, 2014 at 07:37:09PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
On Wednesday, 13 August 2014 at 18:58:59 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at 06:31:32PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
[...]
I've used your
On Wednesday, 13 August 2014 at 19:43:20 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at 07:37:09PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
On Wednesday, 13 August 2014 at 18:58:59 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at
On Wed, Aug 13, 2014 at 07:58:49PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
On Wednesday, 13 August 2014 at 19:43:20 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at 07:37:09PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
On Wednesday, 13 August
On Wednesday, 13 August 2014 at 20:27:29 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at 07:58:49PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
On Wednesday, 13 August 2014 at 19:43:20 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at
On Wed, Aug 13, 2014 at 08:52:32PM +, via Digitalmars-d-learn wrote:
On Wednesday, 13 August 2014 at 20:27:29 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Wed, Aug 13, 2014 at 07:58:49PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
On Wednesday, 13 August 2014 at 19:43:20
On Monday, 11 August 2014 at 20:02:38 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
opApplyReverse.
Was that a joke or does opApplyReverse exist?
On Tue, 12 Aug 2014 16:50:33 +
Gary Willoughby via Digitalmars-d-learn
digitalmars-d-learn@puremagic.com wrote:
Was that a joke or does opApplyReverse exist?
it's not a joke.
http://dlang.org/statement.html
ctrl+f, opApplyReverse
signature.asc
Description: PGP signature
On Tuesday, 12 August 2014 at 17:00:26 UTC, ketmar via
Digitalmars-d-learn wrote:
On Tue, 12 Aug 2014 16:50:33 +
Gary Willoughby via Digitalmars-d-learn
digitalmars-d-learn@puremagic.com wrote:
Was that a joke or does opApplyReverse exist?
it's not a joke.
http://dlang.org/statement.html
Just for a bit a fun i've implemented a simple doubly linked list
and trying out some range based stuff. Whilst doing so i have
some questions which you guys might be able to answer.
1. In your opinion when accessing the elements of a linked list
should they yield the data stored within
On Mon, Aug 11, 2014 at 05:51:11PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
Just for a bit a fun i've implemented a simple doubly linked list and
trying out some range based stuff. Whilst doing so i have some
questions which you guys might be able to answer.
1. In your opinion
On Monday, 11 August 2014 at 18:20:51 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
If you make your linked list container the same thing as a
range over it, then iterating over the range will empty the
container as
well, which generally isn't what you want.
Yes but only if it's been
On Mon, Aug 11, 2014 at 07:35:04PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
On Monday, 11 August 2014 at 18:20:51 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
If you make your linked list container the same thing as a range over
it, then iterating over the range will empty
On Monday, 11 August 2014 at 20:02:38 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
On Mon, Aug 11, 2014 at 07:35:04PM +, Gary Willoughby via
Digitalmars-d-learn wrote:
On Monday, 11 August 2014 at 18:20:51 UTC, H. S. Teoh via
Digitalmars-d-learn wrote:
If you make your linked list
1 - 100 of 127 matches
Mail list logo