Tue, 28 Jul 2009 04:53:02 -0400, bearophile thusly wrote:
> Such optimizations require brain and maybe even planning. So they have
> to be discussed first.
The discussion or collective community opinion won't help a bit. Walter
is the only person who decides what goes into the spec and what does
Tue, 28 Jul 2009 04:57:57 -0400, Kagamin thusly wrote:
> Andrei Alexandrescu Wrote:
>
>> > I know you said you didn't
>> > really like the idea of having to name your range's empty function
>> > 'opGet_empty'.
>>
>> Correct. I'd rather try to disambiguate the rather rare case when a
>> property
Mon, 27 Jul 2009 22:57:09 -0500, Andrei Alexandrescu thusly wrote:
> Correct. I'd rather try to disambiguate the rather rare case when a
> property returns a delegate etc. For me, I get a breath of fresh air
> whenever I get to not write "()". I can't figure how some are missing
> it.
You would l
Tue, 28 Jul 2009 11:38:36 -0400, Adam D. Ruppe thusly wrote:
> On Tue, Jul 28, 2009 at 12:23:50PM -0300, Ary Borenszweig wrote:
>> But *why* use or make another one when the Tango one is already
>> excellent? :(
>
> Copyright.
There are most likely several issues that prevent the reuse of that c
Wed, 29 Jul 2009 08:58:32 -0400, Jarrett Billingsley thusly wrote:
> (Of course I find the whole property
> syntax used for type introspection a bit silly, a half-thought-out
> feature that's hard to parse, not easily extensible, and which doesn't
> fit syntactically with the rest of the metaprogr
Wed, 29 Jul 2009 11:46:53 +, Moritz Warning thusly wrote:
> On Tue, 28 Jul 2009 16:46:51 -0700, Bill Baxter wrote:
>
>> One more thing I'd like to mention regarding properties.
>>
>> It has long annoyed me that .sort and .reverse are functions, but
>> CANNOT be called like functions.
>> So e
Wed, 29 Jul 2009 09:55:40 -0400, Jarrett Billingsley thusly wrote:
> so its various
> introspection capabilities are kind of .. organically grown.
> ...
> __traits is ugly only because W wanted it to be.
Good points.. that could also be the case. Now that the D 2.0
specification has not been fr
Wed, 29 Jul 2009 13:20:06 -0400, Dimitar Kolev thusly wrote:
> Okay correct me if I am wrong but why not make properties like that:
>
> class a
> {
> int #a;
> }
>
> The compiler can expand this to:
>
> int property_a(int new_a)
> {
> return this.a = new_a;
> }
>
> int property_a()
>
Wed, 29 Jul 2009 16:01:33 -0400, Dimitar Kolev thusly wrote:
> Where is the slow part when you have inline?
What inline do I have? Are you suggesting that the keyword should be
resurrected?
Wed, 22 Jul 2009 16:20:36 -0700, Walter Bright thusly wrote:
> Jarrett Billingsley wrote:
>> Ha. Had D differed *too* much from C++, then we'd run the risk of
>> scaring off the C++ snobs simply because it wasn't familiar enough to
>> them.
>
> It's a good point. Radically different languages te
Thu, 30 Jul 2009 21:57:33 +0200, downs thusly wrote:
> As it stands, the claim on the homepage that it's easier to implement a
> D compiler than a C++ one is highly dubious.
Isn't D simpler to implement than C++ because the template syntax goes
like !(foo) instead of ?
Fri, 07 Aug 2009 04:46:37 +1000, Daniel Keep thusly wrote:
> Search: (o) the whole site (o) D1 (o) D1 (spec) (o) D1 (phobos) (o) D2
> (o) D2 (spec) (o) D2 (phobos) (o) Newsgroups (o) Newsgroups (D-only) (o)
> Newsgroups (D-only, but not including D.bugs) (o) Pages that include
> changes between D1
Thu, 06 Aug 2009 17:06:40 -0300, Ary Borenszweig thusly wrote:
> Of course I think using "//" for something else is a disaster.
The -- token may look too functional to many of us. I am pretty sure that
a great deal of D users would choose a buggy, badly optimizing compiler
and an incomplete spe
Fri, 07 Aug 2009 12:50:25 +0200, Lars T. Kyllingstad thusly wrote:
> In the 'proposed syntax change' thread, Don mentioned that an
> exponentiation operator is sorely missing from D. I couldn't agree more.
> ...
> "Why do we need this?" you say. "Isn't pow(a,b) good enough?" And yes,
> pow(a,b)
Sat, 08 Aug 2009 19:26:48 -0600, Rainer Deyke thusly wrote:
>
> I don't think D needs two inline comment forms, but /+...+/ is no less
> ambiguous than /*...*/. Don't forget about the unary '+' operator:
We could also overload .. to define a vector dot product, and *** for
cross product.
Tue, 11 Aug 2009 00:37:46 -0400, Jeremie Pelletier thusly wrote:
> I wouldn't be surprised to see major games releases built in D in a few
> years.
It's quite optimistic to think that the toolchain will be usable and
robust enough on the large scale in a few years. For instance adding the
keywo
Tue, 11 Aug 2009 19:04:50 +1000, Daniel Keep thusly wrote:
> I'm personally of the mindset that beginners should most definitely not
> be attempting to learn D as their first language. Languages like D, C,
> C++ are horribly unsuitable because they force you to understand how the
> machine works
Mon, 10 Aug 2009 14:15:41 -0400, bearophile thusly wrote:
> Steven Schveighoffer:
>> My point is, don't count on having 2GB of usable space even if you
>> physically have 2GB of RAM, it may not be the case.
>
> I was looking for using 1.8 GB not 2.
>
>
>>Better off to not desire than to complai
Tue, 11 Aug 2009 12:58:59 +, language_fan thusly wrote:
> I even think that if your OS supports page
> files, it doesn't matter if the memory is on chip or disk - if the
> memory is split 3/1 for processes and kernel, you should be able to
> allocate 2 GB easily.
For exam
Wed, 12 Aug 2009 00:06:03 +1000, Daniel Keep thusly wrote:
> It sounds good in theory, but it doesn't seem to hold up in practice.
Why? Has there been any non-successful attemps in this direction?
Many constructs of D for which semantics can be defined with a collection
of simpler constructs co
Wed, 12 Aug 2009 10:22:22 -0400, Jarrett Billingsley thusly wrote:
> but DMD crashes. :P
Who would have guessed! It would help if the compiler knew how to do
semantic analysis.. here are a couple of additional test cases - a type
checker for these can be written in approximately 30 minutes in
Wed, 12 Aug 2009 15:19:10 +, language_fan himself wrote:
> Wed, 12 Aug 2009 10:22:22 -0400, Jarrett Billingsley thusly wrote:
>
>> but DMD crashes. :P
>
> Who would have guessed! It would help if the compiler knew how to do
> semantic analysis.. here are a couple of
Wed, 26 Aug 2009 15:42:35 +, BCS thusly wrote:
> Hello Leandro,
>
>>> I have a copy of Walter's internal DMD test suite, so I could actually
>>>
>> What was the reason not to release the test suite? Copyright?
>>
>>
> bingo. The code comes from all kinds of palaces and IIRC Walter doesn't
Thu, 20 Aug 2009 16:11:14 -0400, Nick Sabalausky thusly wrote:
> "Lutger" wrote in message
> news:h6j06p$24v...@digitalmars.com...
>>
>> - how the distro deals with patented and closed source software. (mp3,
>> dvd,
>> flash, video drivers, etc)
>
> That's a good point. Ubuntu doesn't have mp3,
Wed, 19 Aug 2009 19:46:21 -0400, Adam D. Ruppe thusly wrote:
> On Wed, Aug 19, 2009 at 07:34:19PM -0400, Justin wrote:
>> I think that the separate partition for /home is a good idea, generally
>> speaking. It can be a lifesaver if you enjoy hacking around the system
>> and manage to royally screw
Wed, 26 Aug 2009 12:15:28 -0700, Walter Bright thusly wrote:
> language_fan wrote:
>> Wed, 26 Aug 2009 15:42:35 +, BCS thusly wrote:
>>
>>> Hello Leandro,
>>>
>>>>> I have a copy of Walter's internal DMD test suite, so I could
>>>
Fri, 28 Aug 2009 08:18:57 -0500, Andrei Alexandrescu thusly wrote:
> Same here! And the step looked unconceivable just a couple months
> earlier. I remember how a friend who was in the beginning stages of
> Linux asked me several times and very incredulously: "What do you mean
> you don't have Win
Sat, 29 Aug 2009 11:14:15 -0400, A Bothe thusly wrote:
> What's your favorite line of D code?
>
> My one is
> Application.Run();
>
> And yours?
foreach(Problem p; World.problems) find_answer_to(p);
It just always seems to get stuck.
Sat, 29 Aug 2009 13:45:23 -0300, Ary Borenszweig thusly wrote:
> A Bothe escribió:
>> What's your favorite line of D code?
>>
>> My one is
>> Application.Run();
>
> Isn't that C#? :-)
>
> I think a favorite line of D code should have a feature of D that
> doesn't appear in any other language...
Sun, 30 Aug 2009 14:34:36 -0700, Walter Bright thusly wrote:
> http://www.reddit.com/r/programming/comments/9fk6g/
how_nested_functions_work_part_1/
This seems more like an advertisement of D than practical new information
for compiler construction. Nesting functions is the basic feature of
fun
Mon, 31 Aug 2009 10:37:29 -0700, Walter Bright thusly wrote:
> language_fan wrote:
>> This seems more like an advertisement of D than practical new
>> information for compiler construction. Nesting functions is the basic
>> feature of functional languages. Moreover even p
Wed, 02 Sep 2009 10:28:58 +0200, downs thusly wrote:
> Robert Fraser wrote:
>> downs wrote:
>>> foo.betweens("src=\"", "\"") /select/ (string s) { return
>>> s.find(criteria) != -1; }
>>
>> Heh, I love that infix expression syntax. Too abd it ends up with a
>> completely useless wrapper stru
Mon, 31 Aug 2009 13:17:11 -0700, Walter Bright thusly wrote:
> I agree it would be better to allow forward references for nested
> functions, I just wished to point out that the current behavior is not a
> bug, it was built that way.
That's great news actually. It might even mean that this might
Wed, 02 Sep 2009 13:35:05 +0200, Michiel Helvensteijn thusly wrote:
> language_fan wrote:
>
>>> I agree it would be better to allow forward references for nested
>>> functions, I just wished to point out that the current behavior is not
>>> a bug, it was built t
Mon, 31 Aug 2009 14:42:09 -0400, Jeremie Pelletier thusly wrote:
> I agree with Walter here. While D is not the first place I see closures
> and nested functions, it is the first language I come across that blends
> delegates, closures and nested functions in a simple, elegant and
> intuitive mann
Tue, 08 Sep 2009 17:25:08 -0400, Justin Johansson thusly wrote:
> D is to C++ as Scala is to Java.
The word you are looking for may be 'successor'.
> The very articulate Paul Graham writes in "The Hundred-Year Language"
> http://www.paulgraham.com/hundred.html "Though the situation is better
> i
Tue, 08 Sep 2009 18:09:01 -0400, bearophile thusly wrote:
> CLisp macros are not pure at all, Scheme macros are a bit less dirty :-)
Even though conversation on this newsgroup is mostly bikeshedding, it is
wrong to use confusing new unestablished terms like dirtyness. The
correct word is hygien
Thu, 10 Sep 2009 03:21:10 -0400, Nick Sabalausky thusly wrote:
>> I really really hope that my current excitement with D continues and
>> that another 30-60 days down the track I don't end up becoming
>> disillusioned with D as I did with Scala.
>>
>>
> As someone who's been meaning to take a loo
Thu, 10 Sep 2009 04:18:58 -0400, #ponce thusly wrote:
>> At least the problem with many old-school developers is that even
>> though a new language is 10x more readable, 100x more flexible, 1000x
>> safer and 1x faster to develop with, if it's 0.1% slower than C++,
>> they have no reason to us
Thu, 10 Sep 2009 04:18:58 -0400, #ponce thusly wrote:
> See python internal objects size :
> http://www.codexon.com/posts/memory-size-of-python-objects Everything
> takes 4x the memory it would take in D. Each field access seems to be a
> lookup into a hashmap. This is plain ugly.
Python is not t
Thu, 10 Sep 2009 06:05:59 -0400, Nick Sabalausky thusly wrote:
> "#ponce" wrote in message
> news:h8acpi$21u...@digitalmars.com...
>>> At least the problem with many old-school developers is that even
>>> though a new language is 10x more readable, 100x more flexible, 1000x
>>> safer and 1x f
Thu, 10 Sep 2009 16:49:47 -0400, Nick Sabalausky thusly wrote:
> "language_fan" wrote in message
>> Nowadays when everyone soon has 12-core CPUs in front of them,
>> especially x86-64 ones, managing each register and memory module (cache
>> or main memory) manu
Thu, 10 Sep 2009 20:25:04 -0400, Justin Johansson thusly wrote:
> 2. Scala cannot make up her mind if she's a scripting language or
> serious language. Optional semicolons at the end of statements are
> really frustrating for code style consistency. Worst when sometimes you
> need them and you l
Fri, 11 Sep 2009 09:34:54 +0200, Don thusly wrote:
> dsimcha wrote:
>> == Quote from Nick Sabalausky (a...@a.a)'s article
>>> In general though, I find the "programmer time is more expensive than
>>> hardware" line to largely be a cop-out.
>>
>> Fair enough, but can you elaborate on this? Of cou
Fri, 11 Sep 2009 16:10:28 +, BCS thusly wrote:
> If I ever am in a position to do it, I will mandate that executive demos
> will always be first done using a 10-25th percentile machine from our
> current target market. Only once it is shown to run reasonably on that,
> will the team be allowed
Fri, 11 Sep 2009 16:33:56 +, BCS thusly wrote:
> First, I have zero interest in game development so that's not an issue
> for me.
Game development is one of the largest users of systems programming
languages.
> OK so the lead knows that they can make things x times faster. Well then
> the d
Fri, 11 Sep 2009 16:16:07 -0400, Justin Johansson thusly wrote:
>> > Another point related to maintenance costs is the choice of language.
>> > Many smaller companies choose "easier" languages like php, visual
>> > basic, or python for their applications because they outsource
>> > library writing
Fri, 11 Sep 2009 22:41:32 +, BCS thusly wrote:
> Hello language_fan,
>
>> Fri, 11 Sep 2009 16:33:56 +, BCS thusly wrote:
>>
>>> First, I have zero interest in game development so that's not an issue
>>> for me.
>>>
>> Game develo
Mon, 14 Sep 2009 07:33:59 -0400, bearophile thusly wrote:
> But lot of people will judge D against more modern languages like C#,
> Scala or Java) and not against C.
Programmers often belong to three kinds of groups. First come the fans of
traditionally weakly typed compiled languages (basic, c,
Mon, 14 Sep 2009 21:55:10 -0600, Rainer Deyke thusly wrote:
> language_fan wrote:
>> The members of the last group have studied computer science and
>> languages, in particular. They have found a pet academic language,
>> typically a pure one, but paradigms may differ
Tue, 15 Sep 2009 00:25:46 +0200, Lutger thusly wrote:
> That's a fancy way of saying that anyone who has not studied CS is a
> moron and therefore cannot understand what is good about languages, thus
> they lose any argument automatically. Am I right?
I just recommend learning basic concepts unti
Tue, 15 Sep 2009 16:41:25 +0200, Lutger thusly wrote:
> language_fan wrote:
>
>> Tue, 15 Sep 2009 00:25:46 +0200, Lutger thusly wrote:
>>
>>> That's a fancy way of saying that anyone who has not studied CS is a
>>> moron and therefore cannot understa
Wed, 16 Sep 2009 12:41:06 +0200, Fawzi Mohamed thusly wrote:
> On 2009-09-16 02:40:02 +0200, Justin Johansson
> said:
>> A colleague of mine is suggesting that I really do take a closer look
>> at D2 now but I'm not sure that I'm ready to go standing on the
>> bleading bleading (the blood doesn'
Thu, 17 Sep 2009 09:46:01 -0500, Andrei Alexandrescu wrote:
> language_fan wrote:
>> Do the various variant structures presented here support recursive type
>> definitions such as lists? Is this done efficiently?
>
> In Phobos' Algebraic, if you mention the type This
Sat, 19 Sep 2009 11:44:33 -0700, Walter Bright thusly wrote:
> Lutger wrote:
>> Cool article, I posted a comment. Reddit seems to be going downhill
>> fast though, it's even worse than slashdot.
>
> I know, the negative comments don't even make any sense.
>
>> Are locally instantiated templates
Sun, 20 Sep 2009 01:09:56 +, language_fan thusly wrote:
> Sat, 19 Sep 2009 11:44:33 -0700, Walter Bright thusly wrote:
>
>> Lutger wrote:
>>> Cool article, I posted a comment. Reddit seems to be going downhill
>>> fast though, it's even worse than sl
>> template C ()
>> {
>> this (int i)
>> {
>> }
>> }
>> class A
>> {
>> mixin C;
>> this ()
>> {
>> }
>> }
>> void main ()
>> {
>> auto a = new A(3);
>> }
Since the constructor has no meaning outside classes, should it be
interpreted as a free function if mixed in a non-class context? I really
w
http://wiki.jvmlangsummit.com/images/a/ab/HickeyJVMSummit2009.pdf
Sun, 20 Sep 2009 16:09:50 -0400, bearophile thusly wrote:
> I'm just a newbie on this stuff, while
> people that write the memset of 64bit glibc are expert.
I have been wondering why people often here complain that Java is slower
than D. Every time I see your benchmarks, Java is actually doing j
Sun, 20 Sep 2009 18:16:37 -0400, bearophile thusly wrote:
> My benchmarks aren't chosen randomly, I naturally focus on things that
> are slower in D, so sometimes you can see Java to "win". I usually
> discard the code where Java results slower :-)
I have seen people many times mention that Java
Mon, 21 Sep 2009 14:01:27 -0400, bearophile thusly wrote:
> Justin Johansson:
>
>>I'd be interested to know how good D is for implementing
>>scripting/dynamic languages .. maybe that could change the odds?<
>
> You can surely implement Ruby or JS or other dynamic languages with D1.
> But I don't
Mon, 21 Sep 2009 13:17:38 -0400, Jeremie Pelletier thusly wrote:
> Justin Johansson wrote:
>> bearophile Wrote:
>>
>>> - Currently D isn't very useful for the web/mobile, where lot of
>>> programmers are.
>>
>> I'd be interested to know how good D is for implementing
>> scripting/dynamic languag
Mon, 21 Sep 2009 15:29:13 -0400, Jeremie Pelletier thusly wrote:
> language_fan wrote:
>> Mon, 21 Sep 2009 14:01:27 -0400, bearophile thusly wrote:
>>
>>> Justin Johansson:
>>>
>>>> I'd be interested to know how good D is for implementing
&g
Mon, 21 Sep 2009 15:07:47 -0400, Jeremie Pelletier thusly wrote:
> language_fan wrote:
>> Mon, 21 Sep 2009 13:17:38 -0400, Jeremie Pelletier thusly wrote:
>>
>>> Justin Johansson wrote:
>>>> bearophile Wrote:
>>>>
>>>>> -
Mon, 21 Sep 2009 20:42:47 +, language_fan thusly wrote:
> I am not talking about getting a degree from some university. I have
> already said that you can read it all yourself if you do not like the
> pace they use to teach the same stuff. But still, it *is* computer
> science
Mon, 21 Sep 2009 23:50:55 +0200, Lutger thusly wrote:
> One is Programming
> language pragmatics, because I wanted to have more background on
> language design (out of interest, trying to follow the discussions
> here...). The other is Patterns of Enterprise Application Architecture
> because my e
Thu, 24 Sep 2009 13:47:21 -0400, Steven Schveighoffer thusly wrote:
> I actually prefer the compiler to handle the casting versus templates to
> cut down on template instantiation bloat.
I wonder how D scales to 100 MLOC programs as the template instantiations
can be troublesome already in < 100
Thu, 24 Sep 2009 14:36:01 -0400, Aenigmatic thusly wrote:
> No further response to any responses to my previous post's responses is
> a both swift and non-invasive.
>
> Now my deeply thought question is ...
>
> Is typedef (in D) a C/C++ legacy or is the dear orphan now adopted as a
> first-class
Thu, 24 Sep 2009 06:17:22 -0400, bearophile thusly wrote:
> There are other ways to make the language more strict, for example
> disallowing some automatic casts, etc. (C# already has some of this, for
> example float => double requires a cast. I don't remember if D2 requires
> this already).
Sin
Thu, 24 Sep 2009 21:13:48 +0200, downs thusly wrote:
> language_fan wrote:
>> Thu, 24 Sep 2009 13:47:21 -0400, Steven Schveighoffer thusly wrote:
>>
>>> I actually prefer the compiler to handle the casting versus templates
>>> to cut down on template instantia
Thu, 24 Sep 2009 15:33:38 -0400, Jarrett Billingsley thusly wrote:
> On Thu, Sep 24, 2009 at 2:36 PM, Aenigmatic
> wrote:
>> No further response to any responses to my previous post's responses is
>> a both swift and non-invasive.
>>
>> Now my deeply thought question is ...
>>
>> Is typedef (in D
Thu, 24 Sep 2009 19:44:09 +, language_fan thusly wrote:
> Thu, 24 Sep 2009 15:33:38 -0400, Jarrett Billingsley thusly wrote:
>
>> On Thu, Sep 24, 2009 at 2:36 PM, Aenigmatic
>> wrote:
>>> No further response to any responses to my previous post's respo
Thu, 24 Sep 2009 18:00:56 -0400, bearophile thusly wrote:
> Walter Bright:
>
>> Executive summary: pure functions and immutable data structures help
>> manage program complexity.
>
> There's something missing in most of the articles I've read that praise
> pure functions and immutable data struc
Wed, 23 Sep 2009 15:09:59 +1000, Daniel Keep thusly wrote:
> See, people equate "parallel execution" with "threads" these days which
> is half the problem. Threads are a TERRIBLE abstraction, because they
> don't. There's no protection. Almost every time I express the opinion
> that threads are
Wed, 23 Sep 2009 10:43:53 -0400, Jeremie Pelletier thusly wrote:
> You're right about concurrency being a different concept than threading,
> but I wouldn't give threading away for a pure concurrent model either.
> I believe D is aiming at giving programmers a choice of the tools they
> wish to
Fri, 25 Sep 2009 00:10:55 +, language_fan thusly wrote:
> You
> may disagree, but I find it much more pleasant to find that the
> application does never crash even though it works 15% slower than an
> optimal C++ code would.
Imagine if a buggy C++ program was monitoring your h
Thu, 24 Sep 2009 21:41:00 -0400, bearophile thusly wrote:
> language_fan:
>
>> [lot of stuff...]
>> Switching to Python is in one way a step in the wrong direction - you
>> lose something you already had for free - [lot of stuff...]
>
> I know several languages
Thu, 24 Sep 2009 20:46:13 -0400, Jeremie Pelletier thusly wrote:
> language_fan wrote:
>> Wed, 23 Sep 2009 10:43:53 -0400, Jeremie Pelletier thusly wrote:
>>
>>> You're right about concurrency being a different concept than
>>> threading,
>>>
Thu, 24 Sep 2009 22:58:51 -0600, Rainer Deyke thusly wrote:
> language_fan wrote:
>> The cost of e.g. doubling computing power depends on the domain. If you
>> are building desktop end user applications, they usually should scale
>> from single core atoms to 8-core high-
Sat, 26 Sep 2009 09:32:55 -0400, Justin Johansson thusly wrote:
> I've had a good poke around the forums and couldn't find anything on
> this so ...
>
> What's the recommended method for dispatching code off the runtime type
> of a variant variable (Phobos D2 std.variant)?
>
> Does one use a bun
Fri, 25 Sep 2009 17:59:06 -0600, Rainer Deyke thusly wrote:
> Software is priced to optimize total income, which is net income per
> unit times number of units sold. Production costs are not factored in
> at all. So the real question is if your $50 software package sells
> enough additional unit
Fri, 25 Sep 2009 20:07:40 -0700, Walter Bright thusly wrote:
> Andrei Alexandrescu wrote:
>> This feature would require changing some protection rules, I think for
>> the better. What do you think?
>
> 1. what are those changes?
>
> 2. did you mean to add executable code to an interface?
This s
Fri, 25 Sep 2009 20:17:12 -0400, bearophile thusly wrote:
> Rich Hickey:
>
>>No, I don't. The post is for Clojure users and shows them a relative
>>comparison they care about, persistent vs transient.< Unless that code
>>is returning a persistent vector and provides thread isolation, it is
>>not
Sat, 26 Sep 2009 12:25:23 -0400, Jeremie Pelletier thusly wrote:
> Justin Johansson wrote:
>> language_fan Wrote:
>>
>>> Sat, 26 Sep 2009 09:32:55 -0400, Justin Johansson thusly wrote:
>>>
>>>> I've had a good poke around the forums and couldn
Sat, 26 Sep 2009 18:28:52 +0200, Lutger thusly wrote:
> a hash literal works like this, index with the typeid to get a function
> ptr you can call:
>
> Algebraic!(int, Foo) a;
> a = 3;
> [ typeid(int) : function { writeln("a is int"); },
> typeid(Foo) : function { writeln("a is Foo"); }
> ] [a.
Sat, 26 Sep 2009 16:50:36 -0400, Jeremie Pelletier thusly wrote:
> Jarrett Billingsley wrote:
>> On Sat, Sep 26, 2009 at 4:18 PM, Jeremie Pelletier
>> wrote:
>>
type Event = Mouse | Key | Move;
>>> This can be confusing, for example the first thing that comes to mind
>>> for me is that Eve
Sat, 26 Sep 2009 14:49:45 -0700, Walter Bright thusly wrote:
> The problem with non-nullable references is what do they default to?
> Some "nan" object? When you use a "nan" object, what should it do?
> Throw an exception?
Well typically if your type system supports algebraic types, you can
defi
Sat, 26 Sep 2009 17:59:45 -0400, Jeremie Pelletier thusly wrote:
> How would you do this then?
>
> void foo(int a) {
> Object foo;
> if(a == 1) foo = new Object1;
> else if(a == 2) foo = Object2;
> else foo = Object3;
> foo.doSomething();
> }
I just LOVE to see ques
Sun, 27 Sep 2009 02:15:33 +0400, Denis Koroskin thusly wrote:
> Until the, non-nullable references are too hard to use to become
> useful, because you'll end up with a lot of initializer functions:
>
> void foo(int a) {
> Object initializeFoo() {
> if (a == 1) return new Objec
Sat, 26 Sep 2009 15:49:06 -0700, Walter Bright thusly wrote:
> I used to work at Boeing designing critical flight systems. Absolutely
> the WRONG failure mode is to pretend nothing went wrong and happily
> return default values and show lovely green lights on the instrument
> panel.
Basically if
Sun, 27 Sep 2009 02:04:06 +0200, Yigal Chripun thusly wrote:
> segfaults are *NOT* a good mechanism to handle errors. An exception
> trace gives you a whole lot more information about what went wrong and
> where compared to a segfault.
Indeed, especially since in the case of D half of the userbas
Sat, 26 Sep 2009 18:38:56 -0500, Andrei Alexandrescu thusly wrote:
> Your code in
> Phobos reflects that perspective. In the RegExp class, for example, you
> very often define a variable at the top of a long function and
> initialize it halfway through it. I trivially replaced such code with
> the
Sat, 26 Sep 2009 18:51:19 -0400, #ponce thusly wrote:
>> Exactly, this is what I mentioned previously. Isn't it ugly compared to
>>
>> type Event = Mouse | Key | Move;
>>
>> void dispatchEvent(Event event) {
>> match(event) {
>> Mouse m => m.squeek();
>> Key k => ...
>>
Sat, 26 Sep 2009 19:27:51 -0400, bearophile thusly wrote:
> Some of the things you have seen at Boeing
> today can be done better, there's some progress in the design of human
> interfaces too. That's why I suggest you to program in dotnet C# for few
> days.
That is a really good suggestion. To m
Sun, 27 Sep 2009 00:08:50 -0400, Jeremie Pelletier thusly wrote:
> Ary Borenszweig wrote:
>> Just out of curiosity: have you ever programmed in Java or C#?
>
> Nope, never got interested in these to tell the truth. I only did C,
> C++, D and x86 assembly in systems programming, I have quite a
> b
Sun, 27 Sep 2009 00:27:14 -0700, Walter Bright thusly wrote:
>> You seem to be under the impression that nothing can be made
>> uncrashable without introducing the possibility of corrupted state.
>> That's hogwash.
What I mean by safe is that no matter what you do, you cannot make the
program cr
Sun, 27 Sep 2009 16:47:51 +, Jesse Phillips thusly wrote:
> The thing is that memory safety is the only safety with code. In
> Walter's examples he very clearly showed that a crash is not unsafe, but
> operating with incorrect values is. He has pointed out that if
> initialization is enforced,
Sun, 27 Sep 2009 12:35:23 -0400, Jeremie Pelletier thusly wrote:
> language_fan wrote:
>> Sun, 27 Sep 2009 00:08:50 -0400, Jeremie Pelletier thusly wrote:
>>
>>> Ary Borenszweig wrote:
>>>> Just out of curiosity: have you ever programmed in Java or C#?
>&g
Mon, 28 Sep 2009 13:27:13 -0400, Steven Schveighoffer thusly wrote:
> On Mon, 28 Sep 2009 12:58:57 -0400, bearophile
> wrote:
>
>> Jarrett Billingsley:
>>
>>> Which do you want? Do you want new features, or do you want things to
>>> be fixed?<
>>
>> The ideas shown in that post are low priority,
Mon, 28 Sep 2009 20:34:44 +, BCS thusly wrote:
> Hello Manfred_Nowak,
>
>> BCS wrote:
>>
>> [...]
>>
>>> I wouldn't want to hire a programer that *habitually* (and
>>> unnecessarily) hacks past a feature designed to prevent bugs.
>>>
>> In the short time of an interview its not possible to
1 - 100 of 175 matches
Mail list logo