So, to print or not to print?

Era Scarecrow via Digitalmars-d digitalmars-d at puremagic.com
Mon Apr 25 23:09:31 PDT 2016


On Tuesday, 26 April 2016 at 04:54:33 UTC, rikki cattermole wrote:
> On 26/04/2016 8:41 AM, Brad Roberts via Digitalmars-d wrote:
>> Something that's been bouncing around in the back of my head 
>> for a while.  I can't decide if it's a good idea or a really 
>> bad one. Consider a series of small modules that are 
>> essentially language mappers.  Something like:
>>
>>     std.adapt.ruby
>>     std.adapt.python
>>     std.adapt.mumble
>>
>> Each could contain little functions that map between idioms 
>> and names from the various languages to the d native version.  
>>  There's no way that we can or should have all those sorts of 
>> little helpers in the core library, but that doesn't mean that 
>> they shouldn't exist or wouldn't be useful.
>
> I like this idea, it would help jump start people too.

  Hmmm interesting. I like and hate it at the same time. So maybe 
having a compile time warning that tells you what it's actually 
called and referring to, and recommending they use the proper 
functions. Maybe making them depreciated. Being familiar with 
another language is fine if it jumps you into D, but I don't want 
to start seeing odd Ruby code everywhere that doesn't make sense. 
On the other hand as a learning/easing tool it could be 
invaluable.

  Depreciated or warnings from the compiler wouldn't be bad, and 
even when compiled where warnings are errors, they would have the 
list straight up of a recommended function call and library to 
use instead.

  If they are merely aliased and nothing else, well I can't see 
the harm in that really, as long as they wean out of it 
eventually.


More information about the Digitalmars-d mailing list