digitalmars.D - The D Language: A sweet-spot between Python and C
- Walter Bright (3/3) Mar 29 2015 http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-be...
- lobo (11/14) Mar 29 2015 The syntax was a big part of D that got me hooked. It just feels
- Jonathan (7/10) Mar 29 2015 I once wrote a few programs using a made up language to dream of
- Andrei Alexandrescu (4/7) Mar 29 2015 Found one more article:
- Joakim (5/14) Mar 29 2015 You posted the same article to reddit, from a different,
- weaselcat (4/7) Mar 29 2015 a lot of the people in the thread are unaware that D even has
- Laeeth Isharc (10/19) Mar 29 2015 Also, there is a perception that you can't use the standard
- Rikki Cattermole (11/31) Mar 29 2015 I'm currently working on the forcing GC cleanup mechanism for my web
- weaselcat (8/52) Mar 29 2015 I actually use D for a pet project of mine(a game! ;) ) and this
- Rikki Cattermole (3/48) Mar 29 2015 Atleast with web servers, a whole bunch of pauses can't be dealt with.
- Laeeth Isharc (4/79) Mar 29 2015 How about we (ie you, the language expert!) jot down a few more
- Rikki Cattermole (8/69) Mar 29 2015 I'm by far not a language expert, especially with manual memory
- Laeeth Isharc (14/28) Mar 30 2015 I like my new oneplusone smart phone, but it doesn't lend itself
http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-between-python-and-c/ Reddit: https://www.reddit.com/r/programming/comments/30qqck/the_d_language_a_sweetspot_between_python_and_c/
Mar 29 2015
On Monday, 30 March 2015 at 00:57:06 UTC, Walter Bright wrote:http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-between-python-and-c/ Reddit: https://www.reddit.com/r/programming/comments/30qqck/the_d_language_a_sweetspot_between_python_and_c/The syntax was a big part of D that got me hooked. It just feels right, as Python syntax often does, but with D there's raw power behind it. Coming from C++ I'd always end up prototyping in Python because it's such a productive language. Unfortunately Python doesn't have the grunt when I need it so it turns into a Python/C++ combo. I tried Go and Rust but found both languages put up roadblocks too often and got in my way. Cheers, lobo
Mar 29 2015
The syntax was a big part of D that got me hooked. It just feels right, as Python syntax often does, but with D there's raw power behind it.I once wrote a few programs using a made up language to dream of my ideal language: D is the closest language that fits the bill. The constructs had language level support of ranges, function scope level imports, pure keyword, unified function call, and string mixins. The only thing missing honestly is proper support for ADTs/Enum-types (with enforcing an exhaustive match when switch/casing).
Mar 29 2015
On 3/29/15 5:56 PM, Walter Bright wrote:http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-between-python-and-c/ Reddit: https://www.reddit.com/r/programming/comments/30qqck/the_d_language_a_sweetspot_between_python_and_c/Found one more article: https://www.reddit.com/r/programming/comments/30qxy6/d_is_a_dragon_bioinformatics/ Andrei
Mar 29 2015
On Monday, 30 March 2015 at 03:37:21 UTC, Andrei Alexandrescu wrote:On 3/29/15 5:56 PM, Walter Bright wrote:You posted the same article to reddit, from a different, disappeared URL, a couple years ago: http://www.reddit.com/r/programming/comments/tzpdh/d_is_a_dragon_or_why_d_matters_for_bioinformatics/http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-between-python-and-c/ Reddit: https://www.reddit.com/r/programming/comments/30qqck/the_d_language_a_sweetspot_between_python_and_c/Found one more article: https://www.reddit.com/r/programming/comments/30qxy6/d_is_a_dragon_bioinformatics/ Andrei
Mar 29 2015
On Monday, 30 March 2015 at 00:57:06 UTC, Walter Bright wrote:http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-between-python-and-c/ Reddit: https://www.reddit.com/r/programming/comments/30qqck/the_d_language_a_sweetspot_between_python_and_c/a lot of the people in the thread are unaware that D even has RAII like C++, and think it's just a GC language like java/etc. Maybe this is something worth mentioning more on the introduction?
Mar 29 2015
On Monday, 30 March 2015 at 04:16:38 UTC, weaselcat wrote:On Monday, 30 March 2015 at 00:57:06 UTC, Walter Bright wrote:Also, there is a perception that you can't use the standard library and nicer language features if you do your own allocation and don't depend on the GC. A guy worrying about hygiene problems mixing GC and Raii libraries. Whereas most garbage is small and fine to use GC for in some applications - only a subset of real time applications suffer from generating gazillions of tiny objects. It would be good to set out somewhere what you lose as regards std library by insisting on using nogc. The point about std.algorithm should be made more prominent.http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-between-python-and-c/ Reddit: https://www.reddit.com/r/programming/comments/30qqck/the_d_language_a_sweetspot_between_python_and_c/a lot of the people in the thread are unaware that D even has RAII like C++, and think it's just a GC language like java/etc. Maybe this is something worth mentioning more on the introduction?
Mar 29 2015
On 30/03/2015 5:25 p.m., Laeeth Isharc wrote:On Monday, 30 March 2015 at 04:16:38 UTC, weaselcat wrote:I'm currently working on the forcing GC cleanup mechanism for my web server. I would like to add, that post GC disabled it can be forced to do a cleanup. But I would go a step further, do a force minimize of memory back to the OS and reserve e.g. 32mb. Really what would be nice is a, reserveMax function that and anything else is free'd back to the OS. The reserve, means that even if you are sloppy and end up using the GC in critical code, it won't matter. The memory is already allocated. Cleaning up can happen during non critical times. After all, if you are using more then e.g. 32mb in critical code, you are doing something wrong.On Monday, 30 March 2015 at 00:57:06 UTC, Walter Bright wrote:Also, there is a perception that you can't use the standard library and nicer language features if you do your own allocation and don't depend on the GC. A guy worrying about hygiene problems mixing GC and Raii libraries. Whereas most garbage is small and fine to use GC for in some applications - only a subset of real time applications suffer from generating gazillions of tiny objects. It would be good to set out somewhere what you lose as regards std library by insisting on using nogc. The point about std.algorithm should be made more prominent.http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-between-python-and-c/ Reddit: https://www.reddit.com/r/programming/comments/30qqck/the_d_language_a_sweetspot_between_python_and_c/a lot of the people in the thread are unaware that D even has RAII like C++, and think it's just a GC language like java/etc. Maybe this is something worth mentioning more on the introduction?
Mar 29 2015
On Monday, 30 March 2015 at 04:35:44 UTC, Rikki Cattermole wrote:On 30/03/2015 5:25 p.m., Laeeth Isharc wrote:I actually use D for a pet project of mine(a game! ;) ) and this is what I do. I leave the GC disabled and essentially just use it as a free store(while not haphazardly abusing it,) and just manually clean it during opportune times. It's also better to have a single pause for a large cleanup than many small pauses, the overhead of actually scanning the memory will kill you.On Monday, 30 March 2015 at 04:16:38 UTC, weaselcat wrote:I'm currently working on the forcing GC cleanup mechanism for my web server. I would like to add, that post GC disabled it can be forced to do a cleanup. But I would go a step further, do a force minimize of memory back to the OS and reserve e.g. 32mb. Really what would be nice is a, reserveMax function that and anything else is free'd back to the OS. The reserve, means that even if you are sloppy and end up using the GC in critical code, it won't matter. The memory is already allocated. Cleaning up can happen during non critical times. After all, if you are using more then e.g. 32mb in critical code, you are doing something wrong.On Monday, 30 March 2015 at 00:57:06 UTC, Walter Bright wrote:Also, there is a perception that you can't use the standard library and nicer language features if you do your own allocation and don't depend on the GC. A guy worrying about hygiene problems mixing GC and Raii libraries. Whereas most garbage is small and fine to use GC for in some applications - only a subset of real time applications suffer from generating gazillions of tiny objects. It would be good to set out somewhere what you lose as regards std library by insisting on using nogc. The point about std.algorithm should be made more prominent.http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-between-python-and-c/ Reddit: https://www.reddit.com/r/programming/comments/30qqck/the_d_language_a_sweetspot_between_python_and_c/a lot of the people in the thread are unaware that D even has RAII like C++, and think it's just a GC language like java/etc. Maybe this is something worth mentioning more on the introduction?
Mar 29 2015
On 30/03/2015 5:48 p.m., weaselcat wrote:On Monday, 30 March 2015 at 04:35:44 UTC, Rikki Cattermole wrote:Atleast with web servers, a whole bunch of pauses can't be dealt with. But one large one, can easily be via load balances.On 30/03/2015 5:25 p.m., Laeeth Isharc wrote:I actually use D for a pet project of mine(a game! ;) ) and this is what I do. I leave the GC disabled and essentially just use it as a free store(while not haphazardly abusing it,) and just manually clean it during opportune times. It's also better to have a single pause for a large cleanup than many small pauses, the overhead of actually scanning the memory will kill you.On Monday, 30 March 2015 at 04:16:38 UTC, weaselcat wrote:I'm currently working on the forcing GC cleanup mechanism for my web server. I would like to add, that post GC disabled it can be forced to do a cleanup. But I would go a step further, do a force minimize of memory back to the OS and reserve e.g. 32mb. Really what would be nice is a, reserveMax function that and anything else is free'd back to the OS. The reserve, means that even if you are sloppy and end up using the GC in critical code, it won't matter. The memory is already allocated. Cleaning up can happen during non critical times. After all, if you are using more then e.g. 32mb in critical code, you are doing something wrong.On Monday, 30 March 2015 at 00:57:06 UTC, Walter Bright wrote:Also, there is a perception that you can't use the standard library and nicer language features if you do your own allocation and don't depend on the GC. A guy worrying about hygiene problems mixing GC and Raii libraries. Whereas most garbage is small and fine to use GC for in some applications - only a subset of real time applications suffer from generating gazillions of tiny objects. It would be good to set out somewhere what you lose as regards std library by insisting on using nogc. The point about std.algorithm should be made more prominent.http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-between-python-and-c/ Reddit: https://www.reddit.com/r/programming/comments/30qqck/the_d_language_a_sweetspot_between_python_and_c/a lot of the people in the thread are unaware that D even has RAII like C++, and think it's just a GC language like java/etc. Maybe this is something worth mentioning more on the introduction?
Mar 29 2015
On Monday, 30 March 2015 at 05:04:57 UTC, Rikki Cattermole wrote:On 30/03/2015 5:48 p.m., weaselcat wrote:How about we (ie you, the language expert!) jot down a few more points to later turn into a short but useful article on how to deal with the GC in practical situations?On Monday, 30 March 2015 at 04:35:44 UTC, Rikki Cattermole wrote:Atleast with web servers, a whole bunch of pauses can't be dealt with. But one large one, can easily be via load balances.On 30/03/2015 5:25 p.m., Laeeth Isharc wrote:I actually use D for a pet project of mine(a game! ;) ) and this is what I do. I leave the GC disabled and essentially just use it as a free store(while not haphazardly abusing it,) and just manually clean it during opportune times. It's also better to have a single pause for a large cleanup than many small pauses, the overhead of actually scanning the memory will kill you.On Monday, 30 March 2015 at 04:16:38 UTC, weaselcat wrote:I'm currently working on the forcing GC cleanup mechanism for my web server. I would like to add, that post GC disabled it can be forced to do a cleanup. But I would go a step further, do a force minimize of memory back to the OS and reserve e.g. 32mb. Really what would be nice is a, reserveMax function that and anything else is free'd back to the OS. The reserve, means that even if you are sloppy and end up using the GC in critical code, it won't matter. The memory is already allocated. Cleaning up can happen during non critical times. After all, if you are using more then e.g. 32mb in critical code, you are doing something wrong.On Monday, 30 March 2015 at 00:57:06 UTC, Walter Bright wrote:Also, there is a perception that you can't use the standard library and nicer language features if you do your own allocation and don't depend on the GC. A guy worrying about hygiene problems mixing GC and Raii libraries. Whereas most garbage is small and fine to use GC for in some applications - only a subset of real time applications suffer from generating gazillions of tiny objects. It would be good to set out somewhere what you lose as regards std library by insisting on using nogc. The point about std.algorithm should be made more prominent.http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-between-python-and-c/ Reddit: https://www.reddit.com/r/programming/comments/30qqck/the_d_language_a_sweetspot_between_python_and_c/a lot of the people in the thread are unaware that D even has RAII like C++, and think it's just a GC language like java/etc. Maybe this is something worth mentioning more on the introduction?
Mar 29 2015
On 30/03/2015 6:43 p.m., Laeeth Isharc wrote:On Monday, 30 March 2015 at 05:04:57 UTC, Rikki Cattermole wrote:I'm by far not a language expert, especially with manual memory management. I can only discuss what I've dealt with my own projects. I have yet to get to the part where I have to actually try to be nogc or pre allocate + buffers. But there will be an article at some point. But only when it is ready to go public. I am sure there will be a lot of interest in an Apache equivalent web server in D. With shared library support.On 30/03/2015 5:48 p.m., weaselcat wrote:How about we (ie you, the language expert!) jot down a few more points to later turn into a short but useful article on how to deal with the GC in practical situations?On Monday, 30 March 2015 at 04:35:44 UTC, Rikki Cattermole wrote:Atleast with web servers, a whole bunch of pauses can't be dealt with. But one large one, can easily be via load balances.On 30/03/2015 5:25 p.m., Laeeth Isharc wrote:I actually use D for a pet project of mine(a game! ;) ) and this is what I do. I leave the GC disabled and essentially just use it as a free store(while not haphazardly abusing it,) and just manually clean it during opportune times. It's also better to have a single pause for a large cleanup than many small pauses, the overhead of actually scanning the memory will kill you.On Monday, 30 March 2015 at 04:16:38 UTC, weaselcat wrote:I'm currently working on the forcing GC cleanup mechanism for my web server. I would like to add, that post GC disabled it can be forced to do a cleanup. But I would go a step further, do a force minimize of memory back to the OS and reserve e.g. 32mb. Really what would be nice is a, reserveMax function that and anything else is free'd back to the OS. The reserve, means that even if you are sloppy and end up using the GC in critical code, it won't matter. The memory is already allocated. Cleaning up can happen during non critical times. After all, if you are using more then e.g. 32mb in critical code, you are doing something wrong.On Monday, 30 March 2015 at 00:57:06 UTC, Walter Bright wrote:Also, there is a perception that you can't use the standard library and nicer language features if you do your own allocation and don't depend on the GC. A guy worrying about hygiene problems mixing GC and Raii libraries. Whereas most garbage is small and fine to use GC for in some applications - only a subset of real time applications suffer from generating gazillions of tiny objects. It would be good to set out somewhere what you lose as regards std library by insisting on using nogc. The point about std.algorithm should be made more prominent.http://blog.experimentalworks.net/2015/01/the-d-language-a-sweet-spot-between-python-and-c/ Reddit: https://www.reddit.com/r/programming/comments/30qqck/the_d_language_a_sweetspot_between_python_and_c/a lot of the people in the thread are unaware that D even has RAII like C++, and think it's just a GC language like java/etc. Maybe this is something worth mentioning more on the introduction?
Mar 29 2015
I like my new oneplusone smart phone, but it doesn't lend itself to thoughtful expression. Yes - understand that, but this bit is what I mean: " I can only discuss what I've dealt with my own projects". One of the best things about Adam Ruppe's books and talks is the way he takes you on the journey of how he figured something out. Humans learn as much by imitating those ahead of them (who seem human and not out of reach) as by book learning. Understand wanting to wait before saying much, but at the moment the GC is one of those effective FUD factors even though my guess is it needn't be for many people who use it as an excuse not to look any further into D. This is what there is currently: http://wiki.dlang.org/Memory_Management http://wiki.dlang.org/Instantiating_Class_Objects_Elsewhere_Than_the_GC_HeapHow about we (ie you, the language expert!) jot down a few more points to later turn into a short but useful article on how to deal with the GC in practical situations?I'm by far not a language expert, especially with manual memory management. I can only discuss what I've dealt with my own projects. I have yet to get to the part where I have to actually try to be nogc or pre allocate + buffers. But there will be an article at some point. But only when it is ready to go public. I am sure there will be a lot of interest in an Apache equivalent web server in D. With shared library support.
Mar 30 2015