Re: Will the D GC be awesome?

2012-10-03 Thread Justin Whear
On Wed, 03 Oct 2012 23:26:05 +0200, DypthroposTheImposter wrote: > D is pretty cool, perhaps someday I can use it instead of C++ and have > cool shit like fast build times, modules, no more bloody headers, sane > templates, CTFE, UFCS etc > > But can the D GC ever be made: > > 1. precise 2. ab

Re: Any interest in libgit bindings?

2012-10-10 Thread Justin Whear
On Wed, 10 Oct 2012 00:46:28 +0200, Andrej Mitrovic wrote: > http://libgit2.github.com/ > > libgit has things like clone/commit/tag, reading/writing git loose > object files. You can easily deflate object files using std.zlib, but > unfortunately there's no git pack file unpacker in libgit (you c

Re: [std.database] at compile time

2011-10-17 Thread Justin Whear
I have a much cleaner, more robust version, but it currently sends the compiler into an infinite loop and I haven't touched it in a couple months. Justin > Am 14.10.2011 22:29, schrieb Justin Whear: >> This is actually possible now. I wrote a little CTFE parser for CREATE >>

Re: Counting passed/failed unit tests

2011-10-24 Thread Justin Whear
core.runtime allows a user-supplied unittest runner. Never used it, but check out http://www.digitalmars.com/d/2.0/phobos/core_runtime.html#moduleUnitTester Justin Alex Rønne Petersen wrote: > Hi, > > Is there any way to count the amount of passed/failed unit tests in a > module or a program

Re: Damn - again!

2011-11-09 Thread Justin Whear
KNode. Steve Teale wrote: > I use the Pan newsreader. In the mornings when I'm looking at > digitalmars.D I regularly make the mistake of editing the panel that > displays the individual posts. > > I'll mark some of the older text and hit delete. At that point you are > hosed. The article disap

Re: Add pragma(error) and pragma(warning) to the language.

2011-11-10 Thread Justin Whear
How would pragma(error) differ from "static assert(false, errorMessageHere)"? Tobias Pankrath wrote: > I'm currently writing some template based code and there are > situations, when I want to issue warnings or errors to users of my code. > > I know of pragma(msg), but the output will be forma

Re: Implementing Half Floats in D

2013-01-28 Thread Justin Whear
On Mon, 28 Jan 2013 15:11:06 -0800, Walter Bright wrote: > http://www.drdobbs.com/cpp/implementing-half-floats-in-d/240146674 > > Anyone care to do the reddit honors? Posted to /r/d_language, perhaps a x-post to /r/programming would be in order? http://www.reddit.com/r/d_language/comments/17gk

Re: Implementing Half Floats in D

2013-01-28 Thread Justin Whear
On Mon, 28 Jan 2013 18:50:22 -0500, Andrei Alexandrescu wrote: > On 1/28/13 6:40 PM, Justin Whear wrote: >> On Mon, 28 Jan 2013 15:11:06 -0800, Walter Bright wrote: >> >>> http://www.drdobbs.com/cpp/implementing-half-floats-in-d/240146674 >>> >>> Anyone

Re: GUI library for D ---- Why do not consider to use GTK+ 3.0 ??

2011-04-07 Thread Justin Whear
Actually GTK+3.0 is the current stable release and the 2.2* series is in maintenance mode. I'd love to see GtkD update to the 3 series soon-- currently using the 2.6 version.

Should reduce take range as first argument?

2012-05-14 Thread Justin Whear
- This could be fixed with a breaking change by making the subject range to be the first parameter. Aside from breaking existing code, are there other obstacles to changing this? Justin Whear

Re: New Traits

2012-05-16 Thread Justin Whear
On Tue, 15 May 2012 01:13:27 +0200, John Maschmeyer wrote: > I implemented some new traits that seemed to have a lot of interest > recently. > > I've implemented parameterNames, isPublic, isPrivate, > isProtected, isPackge, isExport, and codeof traits. > > parameterNames lets you get access to t

Re: New Traits

2012-05-17 Thread Justin Whear
On Thu, 17 May 2012 23:20:01 +0200, John Maschmeyer wrote: > On Thursday, 17 May 2012 at 10:30:26 UTC, Jacob Carlborg wrote: >> Does it work if the lambda is passed to a function: >> >> void foo (int delegate (int x) dg) >> { >> wirteln(__traits(codeof, dg); >> } >> >> foo(x => x + 1); > > Un

Re: Sparse matrix solver libraries

2012-05-23 Thread Justin Whear
On Wed, 23 May 2012 16:16:19 +0200, Vic Kelson wrote: > Hi All. > > OK. I'm sold on using D to develop an experimental hydrologic modeling > code, but I need a sparse linear algebra package. Has anyone either > developed such a package in D or linked to an existing C or C++ library? > There are a

Re: Are programs/OSes written in D more secure than programs written in C/C++?

2012-06-06 Thread Justin Whear
On Thu, 07 Jun 2012 01:01:55 +0200, Alex Rønne Petersen wrote: > On 07-06-2012 00:04, J.Varghese wrote: >> I'm not a programmer, so can someone explain this to me: Will programs >> and operating systems written in D be safer (I speak of both memory >> safety and security bugs) than existing operat

Re: Editable and runnable code sample on dlang.org by Damian Ziemba (nazriel)

2012-07-05 Thread Justin Whear
On Thu, 05 Jul 2012 09:51:50 -0700, H. S. Teoh wrote: > On Thu, Jul 05, 2012 at 12:26:01PM -0400, Andrei Alexandrescu wrote: >> Check this out: on http://dlang.org you can actually click in the code >> example and edit it, then click "Run" and pronto, you see the output! >> >> Damian is actively

Variable interpolation in strings

2012-07-26 Thread Justin Whear
Jonathan M. Davis' recent post about string mixins reminded me of something I put together a couple of months ago: variable interpolation in strings http://dpaste.dzfl.pl/5689d535 Some of the projects I work on have lots of embedded queries which are assembled on the fly (not just values but co

Re: Variable interpolation in strings

2012-07-26 Thread Justin Whear
On Thu, 26 Jul 2012 22:40:25 +0200, Tobias Pankrath wrote: >> My original thought was to allow cool syntax like x!"embedded variable: >> $foo" but template instantiations don't have access to variables from >> instantiation scope (unless you pass them explicitly via alias, >> of course). > > temp

Re: Which D features to emphasize for academic review article

2012-08-09 Thread Justin Whear
On Thu, 09 Aug 2012 17:57:27 +0200, TJB wrote: > Hello D Users, > > The Software Editor for the Journal of Applied Econometrics has agreed > to let me write a review of the D programming language for > econometricians (econometrics is where economic theory and statistical > analysis meet). I wil

Re: Any companies using D?

2011-07-12 Thread Justin Whear
I work at an economics firm and we use D extensively for our in-house tools (our product is web-based).

dmd.conf change for Ubuntu 11.10

2011-10-14 Thread Justin Whear
Changes to gcc or ld in Ubuntu 11.10 require a small addition to prevent linker errors referencing librt. "-L-lphobos2" needs to be added to DFLAGS before "-L-lrt". I spent a long time trying to figure the problem out before I realized that gcc was tacking on a -lphobos2 to the END of the comman

Re: [std.database] at compile time

2011-10-14 Thread Justin Whear
Graham Fawcett wrote: >> >> But you still won't be able to verify the columns to the actual database >> scheme? > > One approach would be to write a separate tool that connects to the > database and writes out a representation of the schema to a source > file. At compile time, the representation

Add duration parsing to core.time?

2013-08-20 Thread Justin Whear
While working on a configuration file parser, I found myself trying to decide which units to use for various time variables (e.g. `expireInterval`) which is silly because we have an excellent Duration structure in core.time. I was pleased to discover that Duration has a toString method which p

Re: Parallel Rogue-like benchmark

2013-08-23 Thread Justin Whear
On Fri, 23 Aug 2013 09:48:54 -0700, H. S. Teoh wrote: > Seriously, I don't understand what's with this obsession with line count > metrics. Here's a 2-line version of the above code: > > struct Tile { int X = void; int Y = void; int T = void; } > struct Room { int X = void; int Y = void; int W =

Re: Front-end release.NEXT

2013-08-30 Thread Justin Whear
On Fri, 30 Aug 2013 14:35:04 -0700, H. S. Teoh wrote: > On Fri, Aug 30, 2013 at 12:43:44PM -0700, Walter Bright wrote: > One of these days I'll have to research a little more how to more easily > identify the merge commit that pulled in a particular commit. Since all > commits only refer to their

Re: [OT] Which IDE / Editor do you use?

2013-09-13 Thread Justin Whear
vim and gvim on linux.

Re: [OT] Which IDE / Editor do you use?

2013-09-13 Thread Justin Whear
On Fri, 13 Sep 2013 20:02:02 +, Justin Whear wrote: > vim and gvim on linux. Unix is my IDE.

Re: [OT] Which IDE / Editor do you use?

2013-09-13 Thread Justin Whear
On Fri, 13 Sep 2013 22:46:45 +0200, Peter Alexander wrote: > On Friday, 13 September 2013 at 20:44:52 UTC, Adam D. Ruppe wrote: >> On Friday, 13 September 2013 at 20:38:00 UTC, Walter Bright wrote: >>> BTW, one veery nice thing about ME is I can run it from a remote >>> console window. >> >> Yea,

Re: [OT] Which IDE / Editor do you use?

2013-09-13 Thread Justin Whear
On Fri, 13 Sep 2013 14:29:02 -0700, H. S. Teoh wrote: > On Fri, Sep 13, 2013 at 11:00:49PM +0200, monarch_dodra wrote: > vim (and all vi-derived editors) is... shall we say, a unique beast all > its own. It requires a different *mode* of thinking (har har) than your > usual GUI-based editors. In

Re: [OT] Which IDE / Editor do you use?

2013-09-13 Thread Justin Whear
On Fri, 13 Sep 2013 18:06:50 -0400, Jonathan M Davis wrote: > I don't actually use any of the GUI controls. It's just useful to have > vim in a window that I can resize (you also get better color choices > than in the shell). Yeah, my .gvimrc is basically just turning off all the GUI elements, the

Re: [OT] Which IDE / Editor do you use?

2013-09-13 Thread Justin Whear
On Sat, 14 Sep 2013 00:09:35 +0200, Adam D. Ruppe wrote: > Actually, my biggest problem with linux is how terrible the operating > system is compared to DOS and Windows. I'm not even kidding, the unix > terminal debacle sucks (maybe good when you had various hardware, but it > is weak next to what

Zimbu

2013-09-13 Thread Justin Whear
Just ran across this: http://www.zimbu.org/ A language by Bram Moolenaar (original author and maintainer of vim). The "Why Zimbu?" section on the right side of the homepage has comparisons to other languages. D is the last comparison, suggesting that it meets all the other qualifications but f

Re: [OT] Which IDE / Editor do you use?

2013-09-14 Thread Justin Whear
On Saturday, 14 September 2013 at 05:15:32 UTC, Jonathan M Davis wrote: On Saturday, September 14, 2013 06:56:10 Paulo Pinto wrote: Am 14.09.2013 00:06, schrieb Jonathan M Davis: > The features that an IDE has that > vim doesn't typically just aren't worth it. e.g. if I'm > stuck doing >

Re: [OT] Which IDE / Editor do you use?

2013-09-14 Thread Justin Whear
On Saturday, 14 September 2013 at 16:20:21 UTC, Jonathan M Davis wrote: On Saturday, September 14, 2013 05:58:51 Nick Sabalausky wrote: Those exist? I've long heard stories about such things, but they seem to be like unicorns or mermaids or bigfoot...fantasy creatures you only ever hear tales

Re: [OT] Which IDE / Editor do you use?

2013-09-16 Thread Justin Whear
On Mon, 16 Sep 2013 15:51:41 -0700, H. S. Teoh wrote: > On Mon, Sep 16, 2013 at 09:53:34PM +0200, Adam D. Ruppe wrote: >> On Monday, 16 September 2013 at 17:04:46 UTC, H. S. Teoh wrote: >> >It's a miniscule time savings, but it does add up when you're editing >> >a complex command-line pipeline. >

Re: compiled code file size

2013-09-20 Thread Justin Whear
On Fri, 20 Sep 2013 18:35:39 +0200, Temtaime wrote: > DMD likes the size. > When compiling, compiler may use GBs of RAM. > In resulting executable there is no dead/unused code elimination. http://imgur.com/W5AMy0P

Re: std.d.lexer : voting thread

2013-10-02 Thread Justin Whear
Yes. I see this effort driving great advances in D's tooling ecosystem.

Re: The "no gc" crowd

2013-10-09 Thread Justin Whear
On Tue, 08 Oct 2013 17:43:45 +0200, ponce wrote: > Yet with D the situation is different and I feel that criticism is way > overblown: > - first of all, few people will have problems with GC in D at all - then > minimizing allocations can usually solve most of the problems - if it's > still a prob

Re: The "no gc" crowd

2013-10-10 Thread Justin Whear
On Wed, 09 Oct 2013 22:30:05 +0200, Adam D. Ruppe wrote: > On Wednesday, 9 October 2013 at 20:10:40 UTC, Justin Whear wrote: >> Related to the latter, it would be really nice to be able to prove that >> a section of code makes no heap allocations/GC collections. > > As a

Re: std.linalg

2013-10-11 Thread Justin Whear
On Fri, 11 Oct 2013 15:42:17 -0700, H. S. Teoh wrote: > On Sat, Oct 12, 2013 at 12:36:08AM +0200, deadalnix wrote: >> First thing. I see std.linarg I have no clue whatsoever what it even >> may be about. Do we really want to have a standard lib with names that >> look like base64 encoded ? > > I

Re: Object.factory() and module name

2013-04-26 Thread Justin Whear
On Fri, 26 Apr 2013 17:36:31 +0200, eles wrote: > On Friday, 26 April 2013 at 15:34:01 UTC, eles wrote: > > Alternatively, a function/variable could be provided inside the module, > returning the module name as a string, so that one could write: > > Object.factory(__MODULE__, ".Human"); Instead

Re: Another company using D

2013-06-17 Thread Justin Whear
On Sun, 16 Jun 2013 17:24:59 +0200, Marco Leise wrote: > Am Sun, 16 Jun 2013 05:10:39 +0200 schrieb "Vladimir Panteleev" > : > >> On Saturday, 15 June 2013 at 08:04:08 UTC, SomeDude wrote: >> > Should we start a page "They're using D" somewhere ? >> >> This page has been the only remaining red l

Re: Another company using D

2013-06-17 Thread Justin Whear
On Mon, 17 Jun 2013 12:26:59 -0400, Steven Schveighoffer wrote: > On Mon, 17 Jun 2013 12:23:59 -0400, deadalnix > wrote: > >> On Monday, 17 June 2013 at 15:48:39 UTC, Justin Whear wrote: >>> I'm mrjnewt from Reddit; I read the newsgroups Mon-Fri and post >>

Re: Another company using D

2013-06-17 Thread Justin Whear
On Mon, 17 Jun 2013 12:49:36 -0400, Andrei Alexandrescu wrote: > On 6/17/13 11:48 AM, Justin Whear wrote: >> I'm mrjnewt from Reddit; I read the newsgroups Mon-Fri and post >> infrequently. The company I work for has been using D since 2008; we >> have quite a few imp

Re: Another company using D

2013-06-17 Thread Justin Whear
On Mon, 17 Jun 2013 21:12:29 +0200, Andrej Mitrovic wrote: > On 6/17/13, Justin Whear wrote: >> we really need folks who can solve problems on their own, ask questions >> once, and not repeat mistakes. > > So basically, people who don't exist. Hah, that's the ide

Re: Another company using D

2013-06-17 Thread Justin Whear
On Mon, 17 Jun 2013 13:22:49 -0500, evansl wrote: > On 06/17/13 10:48, Justin Whear wrote: >> On Sun, 16 Jun 2013 17:24:59 +0200, Marco Leise wrote: >> >>> Am Sun, 16 Jun 2013 05:10:39 +0200 schrieb "Vladimir Panteleev" >>> : >>> >>&g

Re: Another company using D

2013-06-17 Thread Justin Whear
On Mon, 17 Jun 2013 16:20:11 -0400, Andrei Alexandrescu wrote: > On 6/17/13 3:54 PM, Justin Whear wrote: >> On Mon, 17 Jun 2013 21:12:29 +0200, Andrej Mitrovic wrote: >> >>> On 6/17/13, Justin Whear wrote: >>>> we really need folks who can solve problems o

Re: Another company using D

2013-06-17 Thread Justin Whear
On Mon, 17 Jun 2013 12:49:36 -0400, Andrei Alexandrescu wrote: > On 6/17/13 11:48 AM, Justin Whear wrote: >> I'm mrjnewt from Reddit; I read the newsgroups Mon-Fri and post >> infrequently. The company I work for has been using D since 2008; we >> have quite a few imp

Re: Linking C++ with a D-library

2013-06-26 Thread Justin Whear
On Wed, 26 Jun 2013 22:32:55 +0200, Milvakili wrote: > That "magically" solves my problem. Would you mind if I ask you to > define what this initialization is all about or guide me to some > tutorial related to these issues? > > Thanks alot. The function initializes the D runtime library. I be

Re: Compile time executable calling?

2013-07-12 Thread Justin Whear
On Sat, 13 Jul 2013 00:36:21 +0200, Peter Alexander wrote: > On Friday, 12 July 2013 at 20:42:50 UTC, Tofu Ninja wrote: >> So I had an idea recently, wouldn't it be cool to have the ability to >> call an executable at compile time and capture its output. > > How long until D compilers are able to

Re: Component programming

2013-07-31 Thread Justin Whear
On Wed, 31 Jul 2013 12:20:56 +0200, Chris wrote: > This is only losely related to D, but I don't fully understand the > separation of component programming and OOP (cf. > https://en.wikipedia.org/wiki/Component- based_software_engineering#Differences_from_object-oriented_programming). > In an OO f

Re: D component programming is a joke (Was: Re: Component programming)

2013-07-31 Thread Justin Whear
On Thu, 01 Aug 2013 00:23:52 +0200, bearophile wrote: > > The situation should be improved for D/dmd/Phobos, otherwise such D > component programming remains partially a dream, or a toy. > > Bye, > bearophile I disagree with your "toy" assessment. I've been using this chaining, component style

Re: D component programming is a joke (Was: Re: Component programming)

2013-08-02 Thread Justin Whear
On Thu, 01 Aug 2013 22:24:32 -0700, H. S. Teoh wrote: > Now, w.r.t. the roadblocks I alluded to. > > When I first started working on the code, my goal was to maximize usage > of existing Phobos facilities in order to show how many batteries D > already comes with. As it turned out, I could only us

Re: Network server design question

2013-08-05 Thread Justin Whear
On Sun, 04 Aug 2013 21:38:49 +0200, Marek Janukowicz wrote: > If anyone has any idea how to handle the problems I mentioned or has any > idea for more suitable design I would be happy to hear it. It's also > possible I'm approaching the issue from completely wrong direction, so > you can correct m

Re: D game development: a call to action

2013-08-05 Thread Justin Whear
On Mon, 05 Aug 2013 20:18:29 +0200, Jonathan A Dunlap wrote:: > > A) No information about its current status: this is scary if its repo > hasn't been updated in months. > B) Usually are complex to get working in a new project (manually > building or searching for undocumented dependency DLLs) > C)

Re: D game development: a call to action

2013-08-05 Thread Justin Whear
On Mon, 05 Aug 2013 20:59:32 +0200, Jonathan A Dunlap wrote: >> C) Derelict3 is basically just bindings over the C functions--you >> should use any and all documentation, references, and tutorials against >> the C libraries. > > Thanks Justin for the response. Derelict3 does seem to be the librar

Copious Data, the "Killer App" for Functional Programming

2013-08-05 Thread Justin Whear
Interesting presentation here: http://www.infoq.com/presentations/big-data-functional-programming The presenter's functional style matches quite D's component programming quite closely. E.g. the slide at about 21 minutes in. Anyone feel like writing a component-oriented "Big Data" processing sy

Re: Copious Data, the "Killer App" for Functional Programming

2013-08-05 Thread Justin Whear
On Mon, 05 Aug 2013 23:18:11 +, Justin Whear wrote: > Interesting presentation here: > http://www.infoq.com/presentations/big-data-functional-programming > Reddit: http://www.reddit.com/r/programming/comments/1jo427/ copious_data_the_killer_app_for_functional/

Re: D vs Go in real life, part 2. Also, Erlang.

2013-12-05 Thread Justin Whear
On Thu, 05 Dec 2013 16:24:29 +0100, Atila Neves wrote: >> Interesting. Care to convert this post (only a little adjustment >> needed) to a blog and publish with source code? Would make a great >> article. Ask your friends to contribute with descriptions of their >> implementations, too. > > Ask,

Re: phobos dependencies

2013-12-18 Thread Justin Whear
On Thu, 19 Dec 2013 00:51:04 +0100, Meta wrote: > On Wednesday, 18 December 2013 at 23:08:21 UTC, Walter Bright wrote: >> I favor (2), and also (4): >> >> 4. Break kitchen sink modules like std.algorithm into one module per >> algorithm. This should not result in code duplication. > > That seems

OutputRanges and slicing/save()

2014-01-03 Thread Justin Whear
I've run into a design issue surrounding ranges and am looking for advice on the best way to proceed. To illustrate the issue, consider the Shapefile format: a 100 byte header followed by variable-length records. The tricky bit is that the header includes a field which contains the total leng

Re: OutputRanges and slicing/save()

2014-01-04 Thread Justin Whear
On Saturday, 4 January 2014 at 11:22:03 UTC, Jacob Carlborg wrote: On 2014-01-03 23:56, Justin Whear wrote: I've run into a design issue surrounding ranges and am looking for advice on the best way to proceed. To illustrate the issue, consider the Shapefile format: a 100 byte header fol

Re: Graphics Library for D

2014-01-06 Thread Justin Whear
On Sun, 05 Jan 2014 20:10:06 -0800, Adam Wilson wrote: > > If you are interested in helping with a Cinder like library for D and/or > have code you'd like to contribute, let's start talking and see what > happens. I've been writing graphical applications using D and OpenGL on Linux for a few y

Re: Two Questions

2014-02-04 Thread Justin Whear
On Tue, 04 Feb 2014 16:18:24 +, Steve Teale wrote: > Popped into my head today. > > What proportion of the D community develops on Linux of some sort, and > what proportion works with a 64 bit OS? > > And why? 64bit linux. Cause it's open-source Unix(y), that is, the proper design for an

Re: D as A Better C?

2014-02-11 Thread Justin Whear
On Tue, 11 Feb 2014 22:19:12 +, Gary Willoughby wrote: > On Tuesday, 11 February 2014 at 19:43:00 UTC, Walter Bright wrote: >> I've toyed with this idea for a while, and wondered what the interest >> there is in something like this. >> >> The idea is to be able to use a subset of D that does n

Re: Repost: make foreach(i, a; range) "just work"

2014-02-20 Thread Justin Whear
On Thu, 20 Feb 2014 13:04:55 +, w0rp wrote: > > More importantly, this gets in the way of behaviour which may be > desirable later, foreach being able to unpack tuples from ranges. > I would like if it was possible to return Tuple!(A, B) from front() and > write foreach(a, b; range) to interat

Re: Repost: make foreach(i, a; range) "just work"

2014-02-20 Thread Justin Whear
On Thu, 20 Feb 2014 19:34:17 +, w0rp wrote: > On Thursday, 20 February 2014 at 16:30:42 UTC, Justin Whear wrote: > >> Tuple unpacking already works in foreach. This code has compiled since >> at least 2.063.2: >> >> import std.stdio; >> import s

Re: Repost: make foreach(i, a; range) "just work"

2014-02-21 Thread Justin Whear
On Fri, 21 Feb 2014 10:02:43 +, Regan Heath wrote: > On Thu, 20 Feb 2014 16:30:42 -0000, Justin Whear > wrote: > >> On Thu, 20 Feb 2014 13:04:55 +, w0rp wrote: >>> >>> More importantly, this gets in the way of behaviour which may be >>> des

Re: Recent discussion about discussions

2014-03-12 Thread Justin Whear
On Wed, 12 Mar 2014 18:11:50 +, bossfong wrote: > As a "new kid", I'm really baffled by by how much discussion in the > developers scene is done in mailing lists. > I strongly believe that mailing-lists are not suited for heated > discussions on very specific issues. I even belive it's > count

Re: Recent discussion about discussions

2014-03-13 Thread Justin Whear
On Thu, 13 Mar 2014 18:12:16 +, bossfong wrote: > On Wednesday, 12 March 2014 at 18:20:05 UTC, Justin Whear wrote: >> On Wed, 12 Mar 2014 18:11:50 +, bossfong wrote: >> >>> ... >>> I even belive it's counter-productive when comparing the discussi

Re: Recent discussion about discussions

2014-03-13 Thread Justin Whear
On Thu, 13 Mar 2014 21:16:43 +, John Stahara wrote: > > Funny thing: I, another somewhat "new kid," didn't actually realize that > the web forum was the "second-class" citizen here. I could see some > vestiges of NNTP heritage from e.g. the message URLs, but I'd > subconsciously ignored that

Re: Warn about do nothing expressions?

2014-03-28 Thread Justin Whear
On Fri, 28 Mar 2014 19:35:20 +, Frustrated wrote: > > either way, all increment i, which actually never happens in D. As was > pointed out, VS does it properly... D does it wrong. Accept it and stop > trying to validate how D does it so you can say D is correct. > > Not only is it logically

Re: Warn about do nothing expressions?

2014-03-28 Thread Justin Whear
Someone is sure to ask: $ gcc -v Using built-in specs. COLLECT_GCC=gcc COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/4.8/lto-wrapper Target: x86_64-linux-gnu Configured with: ../src/configure -v --with-pkgversion='Debian 4.8.2-16' --with-bugurl=file:///usr/share/doc/gcc-4.8/README.Bugs --enab

Re: Warn about do nothing expressions?

2014-03-31 Thread Justin Whear
On Sat, 29 Mar 2014 16:21:54 +, Frustrated wrote: > > Oh yeah, this makes hell of a lot of sense. I'm the one who's wrong, yet > monarch claims it his is correct and yet clang gives a warning. Great > logic there! I'll be sure to mark every post you have as special so I > can study your logi

Re: Warn about do nothing expressions?

2014-03-31 Thread Justin Whear
On Mon, 31 Mar 2014 16:07:25 +, monarch_dodra wrote: > > The issue is that the legality of this can't be checked at the semantic > phase. > > It depends on *who* the left and right hand sides are. It's obvious in > "i = i++;", but if you start mixing function calls, references and > whatnot,

Re: Why isn't the array lenght property an lvalue?

2014-04-07 Thread Justin Whear
On Mon, 07 Apr 2014 20:14:13 +, Jeroen Bollen wrote: > On Monday, 7 April 2014 at 20:12:48 UTC, Justin Whear wrote: >> On Mon, 07 Apr 2014 19:13:30 +, Jeroen Bollen wrote: >> >>> When I have myarray.length, why isn't that considered an lvalue, >>&g

Re: Why isn't the array lenght property an lvalue?

2014-04-07 Thread Justin Whear
On Mon, 07 Apr 2014 19:13:30 +, Jeroen Bollen wrote: > When I have myarray.length, why isn't that considered an lvalue, > and as a result, why cannot I get a pointer to it? > > It seems kinda dumb, I understand it cannot be changed manually, > but surely you should be able to get a const(type

Does DMD produce working programs on Snow Leopard?

2009-11-02 Thread Justin Whear
I've been trying to get some SDL windowing code to run on Snow Leopard and been getting mysterious bus errors. After some poking around, I think the problems are rather more fundamental in nature. Observe the following code: module test1; import std.stdio; void main() { B b = new B(); }

Re: Does DMD produce working programs on Snow Leopard?

2009-11-02 Thread Justin Whear
Ok, I'll look forward to that. Do you know if 10.6 makes any effort to be backwards compatible? That is, could I build on 10.5 and then distribute to boxes with 10.6 installed? Walter Bright Wrote: > Justin Whear wrote: > > All this is with dmd 1.050 on a Mac Mini running Mac

Re: Semantics of toString

2009-11-05 Thread Justin Whear
Justin Johansson Wrote: > I assert that the semantics of "toString" or similarly named/purposed > methods/functions in many > PL's (including and not limited to D) is ill-defined. > > To put this statement into perspective, I would be most appreciative of D NG > readers > responding with their

Re: Decimal separator

2010-02-12 Thread Justin Whear
nrgyzer Wrote: > Hello everyone, > > I'm trying to split an integer into a integer with decimal points (or char[] > with decimal points). I already know that I can do this with > std.format.doFormat() but I don't know how I can use this to convert my int > (for example... 1) to 10,000. We

Re: Older versions of dmd

2014-07-11 Thread Justin Whear via Digitalmars-d
On Fri, 11 Jul 2014 17:44:28 +, Frustrated wrote: > So why isn't there a link to previous versions of dmd? I have a > regression I need to test out but can't find 2.064! I'd recommend taking a look at digger (https://github.com/CyberShadow/ Digger). Not only can it automatically build old ve

Re: DIP65: Fixing Exception Handling Syntax

2014-07-17 Thread Justin Whear via Digitalmars-d
On Thu, 17 Jul 2014 12:28:33 -0700, Andrei Alexandrescu wrote: > On 7/8/14, 2:31 PM, Brian Schott wrote: >> http://wiki.dlang.org/DIP65 >> >> tldr: There are parser and specification bugs and I want to fix them. >> It will break some poorly-written code, but I think I can automate the >> upgrade p

Re: DIP65: Fixing Exception Handling Syntax

2014-07-17 Thread Justin Whear via Digitalmars-d
On Thu, 17 Jul 2014 14:03:06 -0700, Walter Bright wrote: > On 7/17/2014 1:44 PM, Justin Whear wrote: >> On Thu, 17 Jul 2014 12:28:33 -0700, Andrei Alexandrescu wrote: >> >>> On 7/8/14, 2:31 PM, Brian Schott wrote: >>>> http://wiki.dlang.org/DIP65 >>>&g

Re: DIP65: Fixing Exception Handling Syntax

2014-07-17 Thread Justin Whear via Digitalmars-d
On Thu, 17 Jul 2014 14:43:59 -0700, Walter Bright wrote: > As I posted elsewhere, in the past there were many complaints about the > ( Exception ) syntax and an expressed desire to deprecate it. I was > going along with that. But apparently those people who wanted it > deprecated are either silent

Re: Algebraic Data Types in D?

2014-07-31 Thread Justin Whear via Digitalmars-d
On Thu, 31 Jul 2014 11:42:20 +, Remo wrote: > http://tech.esper.com/2014/07/30/algebraic-data-types/ > > D already has product type it is struct. > But D lacks sum type also called tagged-union. > > Do you think it would be possible to add something like this to D2 ? In addition to the sugg

Re: How to declare a parameterized recursive data structure?

2014-08-15 Thread Justin Whear via Digitalmars-d
On Fri, 15 Aug 2014 18:37:51 +, artemav wrote: > I'm getting an error when trying to compile (DMD64 D Compiler v2.066) > this: > > struct node(T) { > T data; node!T next; > }; > > void main() { > node!int n; > } > > output: > test.d(3): Error: struct test.node!int.node cannot have

Re: [wildly OT] USB->VGA's ever any good?

2014-08-19 Thread Justin Whear via Digitalmars-d
On Tue, 19 Aug 2014 16:44:50 -0400, Nick Sabalausky wrote: > Apologies for going so far OT, but couldn't think of a better place to > ask. > > Anyone know if those USB->VGA devices out there are any good? Also, > reasonable Linux support with them? > > I imagine HDMI->VGA is likely junk, since t

Re: Communication with other languages via wrappers

2014-08-21 Thread Justin Whear via Digitalmars-d
On Thu, 21 Aug 2014 13:20:02 +, seany wrote: > I am starting this thread to quench my thirst for knowledge. > > I notice, that the existing wrappers to other languages are: > > C: D can natively interface to C > C++ : Some interfacing possible > Lua

Re: RFC: std.json sucessor

2014-08-21 Thread Justin Whear via Digitalmars-d
Someone needs to make a "showbrianmycode" bot: mention a D github repo and it runs static analysis for you.

Re: Multiple Inhertiance?

2014-11-05 Thread Justin Whear via Digitalmars-d
On Thu, 06 Nov 2014 00:39:11 +, Patrick Jeeves wrote: > So what's bothering me is that I can do this: > > class NullType {} > class Monkey(T) : T {} > class Zombie(T) : Monkey!T {} > class Robot(T) : Monkey!T {} > class Pirate(T) : Monkey!T {} > class Ninja(T) : Monkey!T {} > > class Multi

Re: Game development

2015-01-08 Thread Justin Whear via Digitalmars-d
On Thu, 08 Jan 2015 23:02:26 +0200, ketmar via Digitalmars-d wrote: > but yes, i want to create an impression that timewasters are not > welcome. Ironically this is exactly why I'm putting you on my ignored authors list. --Justin

Re: Data-Oriented Demo: SOA, composition via crazy 'using'

2015-01-22 Thread Justin Whear via Digitalmars-d
On Wed, 21 Jan 2015 19:12:20 +, Fool wrote: > Jonathan Blow published another video [1] presenting the progress of his > language. He is treating two main topics: > > - a keyword preliminary called 'using' which seems to be quite > close to 'alias this'; > - an annotation SOA for pointers

Re: Data-Oriented Demo: SOA, composition via crazy 'using'

2015-01-22 Thread Justin Whear via Digitalmars-d
On Thu, 22 Jan 2015 17:40:17 +, Justin Whear wrote: > I just whacked this out in D: http://dpaste.dzfl.pl/90d96cf05792 Remembered the allMembers trait, using a pointer to parent, etc: http:// dpaste.dzfl.pl/6fd66ae9b767

Re: Data-Oriented Demo: SOA, composition via crazy 'using'

2015-01-22 Thread Justin Whear via Digitalmars-d
On Thu, 22 Jan 2015 18:03:31 +, Justin Whear wrote: > On Thu, 22 Jan 2015 17:40:17 +0000, Justin Whear wrote: > >> I just whacked this out in D: http://dpaste.dzfl.pl/90d96cf05792 > > Remembered the allMembers trait, using a pointer to parent, etc: http:// > dpaste.dzf

Re: sortUniq

2015-01-22 Thread Justin Whear via Digitalmars-d
On Thu, 22 Jan 2015 13:40:56 -0800, Andrei Alexandrescu wrote: > There's this classic patter on Unix: |sort|uniq, i.e. sort some data and > only display the unique elements. > > What would be a better integrated version - one that does sorting and > uniq in one shot? I suspect the combination cou

Re: Data-Oriented Demo: SOA, composition via crazy 'using'

2015-01-22 Thread Justin Whear via Digitalmars-d
On Thu, 22 Jan 2015 21:04:04 +, Kiith-Sa wrote: > Could you put this up on GitHub/dub? Even if simple this could be very > useful. Added some features and a dynamic array implementation, put it up here: https://github.com/economicmodeling/soa

Re: [WORK] groupBy is in! Next: aggregate

2015-01-23 Thread Justin Whear via Digitalmars-d
On Fri, 23 Jan 2015 10:08:30 -0800, Andrei Alexandrescu wrote: > So H.S. Teoh awesomely took > https://github.com/D-Programming-Language/phobos/pull/2878 to > completion. We now have a working and fast relational "group by" > facility. > This is great news. It seems like every time I make use o

Re: DIP56 - inlining

2015-02-03 Thread Justin Whear via Digitalmars-d
On Tue, 03 Feb 2015 23:34:15 +, an wrote: > Pragmas can be used as attribute that doesn't affect the semantics. This > syntax is not supported in this DIP? > > pragma(inline, true) > { > void foo() { } > void bar() { } > } I assume it's covered by "If this pragma is outside of a function, it

Re: Let's Play Code Golf

2015-02-23 Thread Justin Whear via Digitalmars-d
On Mon, 23 Feb 2015 20:21:19 +, Charles wrote: > My solution (150 characters, 15 points): > > void main(){import std.stdio;int t,n;readf(" > %d",&t);while(t--){readf(" %d",&n);real > a=0,i=0;for(;i > Link to problem site: https://www.hackerrank.com/challenges/leibniz > > Anyone care t

Re: D Users Survey: Primary OS?

2014-05-29 Thread Justin Whear via Digitalmars-d
On Thu, 29 May 2014 11:24:41 -0700, H. S. Teoh via Digitalmars-d wrote: > On Thu, May 29, 2014 at 10:53:22AM -0500, Tom Browder via Digitalmars-d > wrote: >> Has anyone done a survey of the primary OS of D users? >> >> I (a D newbie) use Debian Linux (64-bit), but I get the feeling that >> many (

  1   2   >