Re: renamepalooza time

2011-01-22 Thread Don
Jonathan M Davis wrote: On Friday, January 21, 2011 06:04:53 spir wrote: On 01/21/2011 09:44 AM, Jonathan M Davis wrote: Well, entab, I'd argue_does_ follow the naming convention, because entab would be a verb, albeit a made up one. Certainly, en is a prefix, not another word, so I think that

Re: DVCS

2011-01-22 Thread Walter Bright
Andrei Alexandrescu wrote: On 1/22/11 12:35 AM, Walter Bright wrote: Phobos1 on 10.10 is dying in its unit tests because Ubuntu changed how gcc's strtof() works. Erratic floating point is typical of C runtime library implementations (the transcendentals are often sloppily done), which is why

Re: easy to upgrade OS (was Re: DVCS)

2011-01-22 Thread Walter Bright
Gour wrote: I'm very seriously considering to put PC-BSD on my desktop and of several others in order to reduce my admin-time required to maint. all those machines. OSX is the only OS (besides DOS) I've had that had painless upgrades. Windows upgrades never ever work in place (at least not

Re: DVCS

2011-01-22 Thread Vladimir Panteleev
On Sat, 22 Jan 2011 08:35:55 +0200, Walter Bright newshou...@digitalmars.com wrote: The only real problem I've run into (so far) is the sunbird calendar has been unceremoniously dumped from Ubuntu. The data file for it is in some crappy binary format, so poof, there goes all my calendar

Re: DVCS

2011-01-22 Thread spir
On 01/22/2011 07:35 AM, Walter Bright wrote: I finally did do it, but as a clean install. I found an old 160G drive, wiped it, and installed 10.10 on it. (Amusingly, the About Ubuntu box says it's version 11.04, and /etc/issue says it's 10.10.) Same for me ;-) _ vita es estrany

Re: easy to upgrade OS (was Re: DVCS)

2011-01-22 Thread spir
On 01/22/2011 09:58 AM, Walter Bright wrote: Gour wrote: I'm very seriously considering to put PC-BSD on my desktop and of several others in order to reduce my admin-time required to maint. all those machines. OSX is the only OS (besides DOS) I've had that had painless upgrades. Windows

Re: DVCS

2011-01-22 Thread spir
On 01/22/2011 10:34 AM, Vladimir Panteleev wrote: On Sat, 22 Jan 2011 08:35:55 +0200, Walter Bright newshou...@digitalmars.com wrote: The only real problem I've run into (so far) is the sunbird calendar has been unceremoniously dumped from Ubuntu. The data file for it is in some crappy binary

Re: easy to upgrade OS (was Re: DVCS)

2011-01-22 Thread retard
Sat, 22 Jan 2011 00:58:59 -0800, Walter Bright wrote: Gour wrote: I'm very seriously considering to put PC-BSD on my desktop and of several others in order to reduce my admin-time required to maint. all those machines. OSX is the only OS (besides DOS) I've had that had painless upgrades.

Re: Ad hoc ranges

2011-01-22 Thread Tomek Sowiński
Andrei Alexandrescu napisał: On 1/21/11 7:35 PM, Tomek Sowiński wrote: Andrei Alexandrescu napisał: Like I said, anything that doesn't bother to expose range-interfaced iterators and is not performance critical is considered a target for ad hoc ranges. Working with non-D libraries, or

Re: back down on Earth [was: Re: Constructors...]

2011-01-22 Thread Pelle
On 01/21/2011 02:02 PM, spir wrote: On 01/21/2011 04:02 AM, Andrei Alexandrescu wrote: That being said, it's not difficult to define a generic function that copies fields over from one class object to another. Here's a start: import std.stdio; void copyMembers(A)(A src, A tgt) if (is(A ==

Re: renamepalooza time

2011-01-22 Thread so
Ever since I worked with STL, I fell in love with names_with_underscores. I can't explain it, but my feeling is that code using that convention is calm and levelheaded. Camel case forces me to think of one-word names because at the second word some beauty is already lost; never felt the

Re: easy to upgrade OS (was Re: DVCS)

2011-01-22 Thread Christopher Nicholson-Sauls
On 01/22/11 03:57, spir wrote: On 01/22/2011 09:58 AM, Walter Bright wrote: Gour wrote: I'm very seriously considering to put PC-BSD on my desktop and of several others in order to reduce my admin-time required to maint. all those machines. OSX is the only OS (besides DOS) I've had that had

Re: Why is the in storage class missing from the ParameterStorageClass enum?

2011-01-22 Thread Christopher Nicholson-Sauls
On 01/20/11 21:57, Andrej Mitrovic wrote: On 1/21/11, Jonathan M Davis jmdavisp...@gmx.com wrote: Umm. in is never the default. in is essentially an alias for const scope. The default is non-shared and mutable. - Jonathan M Davis That's what I thought. But I did saw it mentioned in this

Re: renamepalooza time

2011-01-22 Thread torhu
On 22.01.2011 01:36, Sean Kelly wrote: Andrei Alexandrescu Wrote: Ever since I worked with STL, I fell in love with names_with_underscores. I can't explain it, but my feeling is that code using that convention is calm and levelheaded. Camel case forces me to think of one-word names because

Function/method signatures in D

2011-01-22 Thread Justin Johansson
To inquire precisely, my question is what *exactly* constitutes a function/method signature in D? Aside from functions/methods having an aspect of arity, what can be said in detail about the types of their formal arguments and return type? Cheers, Justin Johansson

Re: renamepalooza time

2011-01-22 Thread Justin Johansson
On 22/01/11 10:55, bearophile wrote: I think variable names in camelcase are less noisy. Sorry, I meant: I think variable names in camelcase are more noisy. Bye, bearophile I think youAre probablyRight (that camelCase is moreNoisy) but unfortunately yourArgument foundered beCause of a

Re: renamepalooza time

2011-01-22 Thread piotrek
On Fri, 21 Jan 2011 18:16:20 -0600, Andrei Alexandrescu wrote: Ever since I worked with STL, I fell in love with names_with_underscores. I can't explain it, but my feeling is that code using that convention is calm and levelheaded. Camel case forces me to think of one-word names because at

Re: easy to upgrade OS (was Re: DVCS)

2011-01-22 Thread Daniel Gibson
Am 22.01.2011 13:21, schrieb retard: Sat, 22 Jan 2011 00:58:59 -0800, Walter Bright wrote: Gour wrote: I'm very seriously considering to put PC-BSD on my desktop and of several others in order to reduce my admin-time required to maint. all those machines. OSX is the only OS (besides DOS)

more naming

2011-01-22 Thread Andrei Alexandrescu
OK, so we have replace(haystack, needle, nail) which replaces _all_ occurrences of needle in haystack with nail. How would you call a function that replaces only the _first_ occurrence of needle with nail? Must be a distinct function, not a runtime parameter to the existing function. This is

Re: easy to upgrade OS (was Re: DVCS)

2011-01-22 Thread Andrej Mitrovic
On 1/22/11, Christopher Nicholson-Sauls ibisbase...@gmail.com wrote: If it was possible to do the same with OS X, I would. (Anyone know a little trick for that, using VirtualBox?) No, that is illegal! But you might want to do a google search for *cough* iDeneb *cough* and download vmware

Re: more naming

2011-01-22 Thread Andrej Mitrovic
What if you want to replace a _count_ number of occurrences of needle in haystack with nail? That's what Python's replace does, although I think that only works for strings in Python.

Re: easy to upgrade OS (was Re: DVCS)

2011-01-22 Thread Daniel Gibson
Am 22.01.2011 17:36, schrieb Andrej Mitrovic: On 1/22/11, Christopher Nicholson-Saulsibisbase...@gmail.com wrote: If it was possible to do the same with OS X, I would. (Anyone know a little trick for that, using VirtualBox?) No, that is illegal! But you might want to do a google search

Re: more naming

2011-01-22 Thread Justin Johansson
On 23/01/11 03:27, Andrei Alexandrescu wrote: OK, so we have replace(haystack, needle, nail) which replaces _all_ occurrences of needle in haystack with nail. How would you call a function that replaces only the _first_ occurrence of needle with nail? Must be a distinct function, not a runtime

Re: more naming

2011-01-22 Thread Andrei Alexandrescu
On 1/22/11 10:47 AM, Andrej Mitrovic wrote: What if you want to replace a _count_ number of occurrences of needle in haystack with nail? That's what Python's replace does, although I think that only works for strings in Python. A specific count is rare but can be added as a defaulted

Re: more naming

2011-01-22 Thread Andrei Alexandrescu
On 1/22/11 11:03 AM, Justin Johansson wrote: On 23/01/11 03:27, Andrei Alexandrescu wrote: OK, so we have replace(haystack, needle, nail) which replaces _all_ occurrences of needle in haystack with nail. How would you call a function that replaces only the _first_ occurrence of needle with

Re: more naming

2011-01-22 Thread Torarin
2011/1/22 Andrei Alexandrescu seewebsiteforem...@erdani.org: OK, so we have replace(haystack, needle, nail) which replaces _all_ occurrences of needle in haystack with nail. How would you call a function that replaces only the _first_ occurrence of needle with nail? Must be a distinct

Re: more naming

2011-01-22 Thread so
It sounds like the current replace should be named replaceAll. Torarin replaceAll replaceN replaceFirst replaceLast

Python's partition

2011-01-22 Thread Andrei Alexandrescu
Looking through Python's string functions (http://docs.python.org/release/2.5.2/lib/string-methods.html) I noticed partition(): partition(sep) Split the string at the first occurrence of sep, and return a 3-tuple containing the part before the separator, the separator itself, and the

Re: more naming

2011-01-22 Thread Andrei Alexandrescu
On 1/22/11 11:38 AM, Torarin wrote: 2011/1/22 Andrei Alexandrescuseewebsiteforem...@erdani.org: OK, so we have replace(haystack, needle, nail) which replaces _all_ occurrences of needle in haystack with nail. How would you call a function that replaces only the _first_ occurrence of needle with

Re: more naming

2011-01-22 Thread Daniel Gibson
Am 22.01.2011 18:46, schrieb Andrei Alexandrescu: On 1/22/11 11:38 AM, Torarin wrote: 2011/1/22 Andrei Alexandrescuseewebsiteforem...@erdani.org: OK, so we have replace(haystack, needle, nail) which replaces _all_ occurrences of needle in haystack with nail. How would you call a function that

Re: more naming

2011-01-22 Thread Adam D. Ruppe
Torarin wrote: It sounds like the current replace should be named replaceAll. That would break lots of existing code, and it doesn't seem to fit. If replacing only the first element means it can take a special range, whereas all other n is is the same, it seems obvious that replaceFirst be the

Re: Python's partition

2011-01-22 Thread so
On Sat, 22 Jan 2011 19:44:30 +0200, Andrei Alexandrescu seewebsiteforem...@erdani.org wrote: Looking through Python's string functions (http://docs.python.org/release/2.5.2/lib/string-methods.html) I noticed partition(): partition(sep) Split the string at the first occurrence of

Re: Python's partition

2011-01-22 Thread Torarin
Divide? As in dividing a pie chart. Torarin

Re: more naming

2011-01-22 Thread Torarin
2011/1/22 Andrei Alexandrescu seewebsiteforem...@erdani.org: That's what I'm fearing - changing current replace to replaceAll and adding replace with the meaning of replaceFirst would silently change the semantics of existing code. Andrei Yeah, I see that problem. I'm just so used to

Re: more naming

2011-01-22 Thread bearophile
Daniel Gibson: IMHO replace (without eny suffix) sounds like it replaces every occurence. So just add replaceFirst for a function that replaces only the first occurence :) OK. Bye, bearophile

Re: Python's partition

2011-01-22 Thread spir
On 01/22/2011 06:44 PM, Andrei Alexandrescu wrote: Looking through Python's string functions (http://docs.python.org/release/2.5.2/lib/string-methods.html) I noticed partition(): partition(sep) Split the string at the first occurrence of sep, and return a 3-tuple containing the part before the

Re: renamepalooza time

2011-01-22 Thread Max Samukha
On 01/22/2011 02:16 AM, Andrei Alexandrescu wrote: On 1/21/11 4:49 PM, Jonathan M Davis wrote: On Friday, January 21, 2011 13:30:11 Ali Çehreli wrote: Andrei Alexandrescu wrote: iswhite I like separating is with an underscore, like most coding styles do: is_whitespace Warm and fuzzy... :)

string splitting funcs

2011-01-22 Thread spir
While we're at tweaking std.string: When writing string libs or types (like Text recently), I implement 3 string splitting methods. This may --or not-- be useful for D's string module. The core point is: what to do with empty parts? They may be generated when: * the separator is present at

Re: Potential patent issues

2011-01-22 Thread Nick Sabalausky
Don nos...@nospam.com wrote in message news:ihcrve$1t5l$1...@digitalmars.com... spir wrote: On 01/21/2011 03:51 PM, Don wrote: Don wrote: BlazingWhitester wrote: I spotted some patents that can theaten current DMD implementation. Wanted to clarify things.

Re: more naming

2011-01-22 Thread spir
On 01/22/2011 05:27 PM, Andrei Alexandrescu wrote: OK, so we have replace(haystack, needle, nail) which replaces _all_ occurrences of needle in haystack with nail. How would you call a function that replaces only the _first_ occurrence of needle with nail? Must be a distinct function, not a

Re: more naming

2011-01-22 Thread Andrej Mitrovic
On 1/22/11, spir denis.s...@gmail.com wrote: In years and years of string processing, I have used maxreplace once, I guess, and the value was not 1. Isn't Andrei talking about std.algorithm.replace, which should work with any range and not just strings?

Re: Potential patent issues

2011-01-22 Thread Jean Crystof
Nick Sabalausky Wrote: I've been under the impression that, as a rule, the USPTO doesn't check for prior art and deliberately leaves invalid due to prior art up to the courts. That's how it works. The patent threat is always there. Someone can patent delegates, classes, and whatever

Re: easy to upgrade OS (was Re: DVCS)

2011-01-22 Thread Walter Bright
retard wrote: Ubuntu doesn't drop support for widely used software. I'd use Google's Calendar instead. I'm really not interested in Google owning my private data.

Re: DVCS

2011-01-22 Thread Walter Bright
Vladimir Panteleev wrote: http://brizoma.wordpress.com/2010/05/04/sunbird-and-lightning-removed-from-ubuntu-10-04-lucid-lynx/ Thanks for finding that. But I think I'll stick for now with the ipod's calendar. It's more useful anyway, as it moves with me.

Re: more naming

2011-01-22 Thread Paul D. Anderson
Daniel Gibson Wrote: Am 22.01.2011 18:46, schrieb Andrei Alexandrescu: On 1/22/11 11:38 AM, Torarin wrote: 2011/1/22 Andrei Alexandrescuseewebsiteforem...@erdani.org: OK, so we have replace(haystack, needle, nail) which replaces _all_ occurrences of needle in haystack with nail. How

Re: DVCS

2011-01-22 Thread retard
Sat, 22 Jan 2011 13:12:26 -0800, Walter Bright wrote: Vladimir Panteleev wrote: http://brizoma.wordpress.com/2010/05/04/sunbird-and-lightning-removed- from-ubuntu-10-04-lucid-lynx/ Thanks for finding that. But I think I'll stick for now with the ipod's calendar. It's more useful anyway, as

replaceFirst, findPieces, and takeExactly

2011-01-22 Thread Andrei Alexandrescu
OK, I added replaceFirst: http://d-programming-language.org/cutting-edge/phobos/std_array.html#replaceFirst http://www.dsource.org/projects/phobos/changeset/2365 I've also added two crucial abstractions that finally quench my many sleepless nights following my Boostcon keynote. Back then

Re: easy to upgrade OS (was Re: DVCS)

2011-01-22 Thread Andrei Alexandrescu
On 1/22/11 3:03 PM, Walter Bright wrote: retard wrote: Ubuntu doesn't drop support for widely used software. I'd use Google's Calendar instead. I'm really not interested in Google owning my private data. Google takes email privacy very seriously. Only last week they fired an employee for

Re: Python's partition

2011-01-22 Thread Christopher Nicholson-Sauls
On 01/22/11 11:44, Andrei Alexandrescu wrote: Looking through Python's string functions (http://docs.python.org/release/2.5.2/lib/string-methods.html) I noticed partition(): partition(sep) Split the string at the first occurrence of sep, and return a 3-tuple containing the part before

Conditional Pure?

2011-01-22 Thread %u
I wanted to suggest a feature similar to inout: conditional purity. That is, sometimes a function is pure iff the delegates passed to it are pure, and as of right now, I don't think there's any way to document this other than by overloading the function as a template (which results in lots of code

Re: Python's partition

2011-01-22 Thread Andrei Alexandrescu
On 1/22/11 3:33 PM, Christopher Nicholson-Sauls wrote: On 01/22/11 11:44, Andrei Alexandrescu wrote: Looking through Python's string functions (http://docs.python.org/release/2.5.2/lib/string-methods.html) I noticed partition(): partition(sep) Split the string at the first occurrence of

Re: renamepalooza time

2011-01-22 Thread Paul D. Anderson
My two cents. (Incidentally, when I learned to type -- in the USA in 1970 -- a cents symbol was standard on the keyboard. Shift-2 or Shift-6, I think.) Jacob Carlborg Wrote: LS - lineSeparator/LineSeparator PS - paragraphSeparator/ParagraphSeparator These are established acronyms:

Re: Python's partition

2011-01-22 Thread bearophile
Andrei Alexandrescu: Would be rather trisect, but that becomes a bit too cute. trisect name is acceptable :-) Bye, bearophile

Re: Python's partition

2011-01-22 Thread foobar
Andrei Alexandrescu Wrote: Looking through Python's string functions (http://docs.python.org/release/2.5.2/lib/string-methods.html) I noticed partition(): partition(sep) Split the string at the first occurrence of sep, and return a 3-tuple containing the part before the separator,

Re: DVCS

2011-01-22 Thread Daniel Gibson
Am 22.01.2011 22:31, schrieb retard: Sat, 22 Jan 2011 13:12:26 -0800, Walter Bright wrote: Vladimir Panteleev wrote: http://brizoma.wordpress.com/2010/05/04/sunbird-and-lightning-removed- from-ubuntu-10-04-lucid-lynx/ Thanks for finding that. But I think I'll stick for now with the ipod's

Re: Conditional Pure?

2011-01-22 Thread bearophile
%u Wrote: I wanted to suggest a feature similar to inout: conditional purity. That is, sometimes a function is pure iff the delegates passed to it are pure, I think this is useless. If this is possible, then you just mark every single not-pure function in the program with @conditionally_pure,

Re: Conditional Pure?

2011-01-22 Thread %u
I think this is useless. If this is possible, then you just mark every single not-pure function in the program with @conditionally_pure, and we are back to the beginning. Oh, but that's not what I meant! I meant something like this: int call(TFn)(TFn fn) pure(isPure!(TFn)) if

Re: DVCS

2011-01-22 Thread Walter Bright
Daniel Gibson wrote: And is the support for the graphics chip better, i.e. can you use full resolution? Yes, it recognized my resolution automatically. That's a nice improvement.

Re: easy to upgrade OS (was Re: DVCS)

2011-01-22 Thread Walter Bright
Andrei Alexandrescu wrote: Google takes email privacy very seriously. Only last week they fired an employee for snooping through someone else's email. http://techcrunch.com/2010/09/14/google-engineer-spying-fired/ That's good to know. On the other hand, Google keeps information forever.

Re: DVCS

2011-01-22 Thread Walter Bright
retard wrote: Does the new Ubuntu overall work better than the old one? Would be amazing if the media players are still all broken. I haven't tried the sound yet, but the video playback definitely is better. Though the whole screen flashes now and then, like the video mode is being reset

Re: renamepalooza time

2011-01-22 Thread Nick Sabalausky
Jonathan M Davis jmdavisp...@gmx.com wrote in message news:mailman.804.1295659471.4748.digitalmar...@puremagic.com... Personally, camelcase vs underscores isn't even something that I normally think about. I just always use camelcase. On _rare_ occasion, I might use underscores because it

Re: Python's partition

2011-01-22 Thread Tomek Sowiński
Andrei Alexandrescu napisał: Looking through Python's string functions (http://docs.python.org/release/2.5.2/lib/string-methods.html) I noticed partition(): partition(sep) Split the string at the first occurrence of sep, and return a 3-tuple containing the part before the

Re: more naming

2011-01-22 Thread Nick Sabalausky
Andrei Alexandrescu seewebsiteforem...@erdani.org wrote in message news:ihf0kc$2fqj$1...@digitalmars.com... OK, so we have replace(haystack, needle, nail) which replaces _all_ occurrences of needle in haystack with nail. How would you call a function that replaces only the _first_ occurrence

Re: renamepalooza time

2011-01-22 Thread Ali Çehreli
Jonathan M Davis wrote: On Friday, January 21, 2011 13:30:11 Ali Çehreli wrote: Andrei Alexandrescu wrote: iswhite I like separating is with an underscore, like most coding styles do: is_whitespace Warm and fuzzy... :) Most? I've never dealt with a coding style that had underscores.

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread Nick Sabalausky
Andrei Alexandrescu seewebsiteforem...@erdani.org wrote in message news:ihfm34$jvb$1...@digitalmars.com... On 1/22/11 4:16 PM, bearophile wrote: Andrei: Back then people said that STL's find() is better than D's find() because the former returns an iterator that can be combined with either

Re: Conditional Pure?

2011-01-22 Thread bearophile
%u: Oh, but that's not what I meant! I meant something like this: int call(TFn)(TFn fn) pure(isPure!(TFn)) if (isCallable!(TFn)) { return fn(5); } This way we specify purity based on a static boolean. I see. I'd like a more general-purpose solution, something that

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread Andrei Alexandrescu
On 1/22/11 5:14 PM, Nick Sabalausky wrote: Andrei Alexandrescuseewebsiteforem...@erdani.org wrote in message news:ihfm34$jvb$1...@digitalmars.com... On 1/22/11 4:16 PM, bearophile wrote: Andrei: Back then people said that STL's find() is better than D's find() because the former returns an

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread Tomek Sowiński
Andrei Alexandrescu napisał: On 1/22/11 5:14 PM, Nick Sabalausky wrote: Andrei Alexandrescuseewebsiteforem...@erdani.org wrote in message news:ihfm34$jvb$1...@digitalmars.com... On 1/22/11 4:16 PM, bearophile wrote: Andrei: Back then people said that STL's find() is better than D's

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread so
Yes, I'm absolutely in agreement with the naming (and thrilled too). I imagine a putative user looking through std.algorithm (let's see... what find functions are out there?). That makes findPieces easy to get to, whereas trisect would be oddly situated in the alphabetic list and oddly

Re: Conditional Pure?

2011-01-22 Thread %u
I see. I'd like a more general-purpose solution, something that works with nothrow too and other future attributes too. Funny, that was going to be my next comment. :) The only thing that scares me a bit is that code like this: public(isPublic!(TFn)) static(isStatic!(TFn)) int memoize(TFn)(TFn

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread Andrei Alexandrescu
On 1/22/11 5:41 PM, Tomek Sowiński wrote: Andrei Alexandrescu napisał: On 1/22/11 5:14 PM, Nick Sabalausky wrote: Andrei Alexandrescuseewebsiteforem...@erdani.org wrote in message news:ihfm34$jvb$1...@digitalmars.com... On 1/22/11 4:16 PM, bearophile wrote: Andrei: Back then people said

druntime !!!!

2011-01-22 Thread bioinfornatics
They are something wrong with druntime management!!! Why druntime do not support gdc or ldc2? Its is very crap thing i hope druntime will add soon gdc support. We can send ldc and gdc patch. Thanks for all best regards

Re: Conditional Pure?

2011-01-22 Thread so
nothrow too and other future attributes too. Funny, that was going to be my next comment. :) The only thing that scares me a bit is that code like this: public(isPublic!(TFn)) static(isStatic!(TFn)) int memoize(TFn)(TFn fn) pure(isPure!(TFn)) if (isCallable!(TFn)) { //etc. } A

Re: Conditional Pure?

2011-01-22 Thread bearophile
%u: might turn out a bit unreadable. And, furthermore, I'd *like* to be able to say something like this method returns a shared const value iff the given type is int or long but this won't work with const() or shared() because of their syntax (you can't say const(is(T == int))). Any

Re: renamepalooza time

2011-01-22 Thread so
I'm the same way. Plus, I find it really awkward to constantly type a bunch of underscores. It feels less like typing and more like finger acobatics. It is worse for camelCase, at least you can bind _ to another key. Only one thing i like about camelCase is that, it takes less space.

Re: druntime !!!!

2011-01-22 Thread Robert Clipsham
On 22/01/11 23:58, bioinfornatics wrote: They are something wrong with druntime management!!! Why druntime do not support gdc or ldc2? Its is very crap thing i hope druntime will add soon gdc support. We can send ldc and gdc patch. Thanks for all best regards I've been talking to you on IRC

Re: druntime !!!!

2011-01-22 Thread Daniel Gibson
Am 23.01.2011 01:32, schrieb Robert Clipsham: On 22/01/11 23:58, bioinfornatics wrote: They are something wrong with druntime management!!! Why druntime do not support gdc or ldc2? Its is very crap thing i hope druntime will add soon gdc support. We can send ldc and gdc patch. Thanks for all

Re: druntime !!!!

2011-01-22 Thread Brad Roberts
On 1/22/2011 4:32 PM, Robert Clipsham wrote: On 22/01/11 23:58, bioinfornatics wrote: They are something wrong with druntime management!!! Why druntime do not support gdc or ldc2? Its is very crap thing i hope druntime will add soon gdc support. We can send ldc and gdc patch. Thanks for all

Re: renamepalooza time

2011-01-22 Thread Nick Sabalausky
so s...@so.do wrote in message news:op.vpqi7ngy7dtt59@so-pc... I'm the same way. Plus, I find it really awkward to constantly type a bunch of underscores. It feels less like typing and more like finger acobatics. It is worse for camelCase, Don't see how. iT vs i_t: iT: [i] [hold shift]

Re: renamepalooza time

2011-01-22 Thread Andrej Mitrovic
That's why they invented the concept of rebinding the keys. And why Vim is a modal editor. Etc etc etc..

Re: Conditional Pure?

2011-01-22 Thread %u
Any ideas on how we might be able to get that to work? @optional_tag(is(T == int) || is(T == long)), const) Ouch... a bit less pretty than I'd hoped (the underscore makes it a bit ugly IMHO). Does it really need to be a tag, though? Why not just: optional(const, is(T == int) || is(T ==

Re: Conditional Pure?

2011-01-22 Thread Michel Fortin
On 2011-01-22 21:34:52 -0500, %u wfunct...@hotmail.com said: Any ideas on how we might be able to get that to work? @optional_tag(is(T == int) || is(T == long)), const) Ouch... a bit less pretty than I'd hoped (the underscore makes it a bit ugly IMHO). Does it really need to be a tag,

Re: renamepalooza time

2011-01-22 Thread spir
On 01/23/2011 12:03 AM, Ali Çehreli wrote: Jonathan M Davis wrote: On Friday, January 21, 2011 13:30:11 Ali Çehreli wrote: Andrei Alexandrescu wrote: iswhite I like separating is with an underscore, like most coding styles do: is_whitespace Warm and fuzzy... :) Most? I've never dealt

Re: renamepalooza time

2011-01-22 Thread spir
On 01/23/2011 02:39 AM, Nick Sabalausky wrote: sos...@so.do wrote in message news:op.vpqi7ngy7dtt59@so-pc... I'm the same way. Plus, I find it really awkward to constantly type a bunch of underscores. It feels less like typing and more like finger acobatics. It is worse for camelCase,

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread spir
On 01/22/2011 11:16 PM, bearophile wrote: That function allows you to pick a determined number of elements from a range, assuming the range is never shorter than that. That sounds a bit obscure, but plays a pivotal role in findParts() (which is the name I settled on for the equivalent of

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread spir
On 01/23/2011 12:40 AM, so wrote: Yes, I'm absolutely in agreement with the naming (and thrilled too). I imagine a putative user looking through std.algorithm (let's see... what find functions are out there?). That makes findPieces easy to get to, whereas trisect would be oddly situated in the

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread spir
On 01/23/2011 12:40 AM, so wrote: Yes, I'm absolutely in agreement with the naming (and thrilled too). I imagine a putative user looking through std.algorithm (let's see... what find functions are out there?). That makes findPieces easy to get to, whereas trisect would be oddly situated in the

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread Daniel Gibson
Am 23.01.2011 04:42, schrieb spir: On 01/23/2011 12:40 AM, so wrote: Yes, I'm absolutely in agreement with the naming (and thrilled too). I imagine a putative user looking through std.algorithm (let's see... what find functions are out there?). That makes findPieces easy to get to, whereas

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread spir
On 01/22/2011 10:27 PM, Andrei Alexandrescu wrote: The first abstraction is the takeExactly() function: http://d-programming-language.org/cutting-edge/phobos/std_range.html#takeExactly That function allows you to pick a determined number of elements from a range, assuming the range is never

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread spir
On 01/23/2011 04:49 AM, Daniel Gibson wrote: splitAt is simply a Good Name! (even better than tripartite ;-) Also for finding it in list of funcs. Denis _ vita es estrany spir.wikidot.com To be honest, tripartite sounds kind of strange. I don't know why, but I think of

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread Andrei Alexandrescu
On 01/22/2011 10:16 PM, spir wrote: On 01/22/2011 10:27 PM, Andrei Alexandrescu wrote: The first abstraction is the takeExactly() function: http://d-programming-language.org/cutting-edge/phobos/std_range.html#takeExactly That function allows you to pick a determined number of elements from

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread spir
On 01/23/2011 05:30 AM, Andrei Alexandrescu wrote: On 01/22/2011 10:16 PM, spir wrote: On 01/22/2011 10:27 PM, Andrei Alexandrescu wrote: The first abstraction is the takeExactly() function: http://d-programming-language.org/cutting-edge/phobos/std_range.html#takeExactly That function

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread Jonathan M Davis
On Saturday 22 January 2011 15:19:39 Andrei Alexandrescu wrote: On 1/22/11 5:14 PM, Nick Sabalausky wrote: Andrei Alexandrescuseewebsiteforem...@erdani.org wrote in message news:ihfm34$jvb$1...@digitalmars.com... On 1/22/11 4:16 PM, bearophile wrote: Andrei: Back then people said

Re: Conditional Pure?

2011-01-22 Thread Jonathan M Davis
On Saturday 22 January 2011 14:41:08 %u wrote: I think this is useless. If this is possible, then you just mark every single not-pure function in the program with @conditionally_pure, and we are back to the beginning. Oh, but that's not what I meant! I meant something like this:

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread Andrei Alexandrescu
On 1/22/11 10:57 PM, spir wrote: On 01/23/2011 05:30 AM, Andrei Alexandrescu wrote: On 01/22/2011 10:16 PM, spir wrote: On 01/22/2011 10:27 PM, Andrei Alexandrescu wrote: The first abstraction is the takeExactly() function:

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread Andrei Alexandrescu
On 1/22/11 10:59 PM, Jonathan M Davis wrote: This will be a _fantastic_ function to have. I think that I probably even have an enhancement request somewhere that includes such a function. It's far too common that you have to find something and you want both what is before and after the point

Re: Python's partition

2011-01-22 Thread Christopher Nicholson-Sauls
On 01/22/11 15:38, Andrei Alexandrescu wrote: On 1/22/11 3:33 PM, Christopher Nicholson-Sauls wrote: On 01/22/11 11:44, Andrei Alexandrescu wrote: Looking through Python's string functions (http://docs.python.org/release/2.5.2/lib/string-methods.html) I noticed partition(): partition(sep)

Re: DVCS

2011-01-22 Thread retard
Sat, 22 Jan 2011 14:47:48 -0800, Walter Bright wrote: retard wrote: Does the new Ubuntu overall work better than the old one? Would be amazing if the media players are still all broken. I haven't tried the sound yet, but the video playback definitely is better. Though the whole screen

Re: replaceFirst, findPieces, and takeExactly

2011-01-22 Thread Jim
Andrei Alexandrescu Wrote: I suspect there might be a simple and intuitive way to define a family of functions that give you whatever portions of the find you're interested in (before, match, after, before and match, match and after). That could be either a naming convention or a template

Re: Type-qualified functions?

2011-01-22 Thread Christopher Nicholson-Sauls
On 01/21/11 14:43, Sean Eskapp wrote: templates: void foo(T)(T, void delegate(T) fn) { } This parameterizes foo based on T, which could be A, const A, or int, or whatever works to compile the function. What if the parameters are more general, for instance the first parameter is

  1   2   >