Deprecated Library Functions / Methods

Johannes Pfau nospam at example.com
Mon Dec 3 08:36:02 PST 2012


Am Mon, 03 Dec 2012 08:37:15 +1100
schrieb Walter Bright <newshound2 at digitalmars.com>:

> On 12/2/2012 10:26 PM, Johannes Pfau wrote:
> > Avoiding breaking code is always a good goal, but I think it's too
> > early for phobos. Code like std.xml, std.outbuffer should have never
> > been a part of phobos. I think one last big break would be best for
> > everyone.
> 
> No, no, no!
> 

OK, I see I won't convince you so we probably won't have a big
break ;-) But I still believe it's too early for phobos to be stable.

In the end we have to choose between stabilizing phobos now or having a
consistent interface (ranges, naming conventions) in all modules.

> > Right now we have can't promise not to break code because
> > we can't keep and support code like std.xml forever
> 
> Yes, we can (or at least for a very long time).

But having broken, unsupported code like that in phobos isn't exactly
good advertising for phobos. And even if we mark it as deprecated and
"don't use this" people will keep using it as long as there is no
alternative and they will still complain if it's removed later on.
> 
> > but we also can't
> > simply remove std.xml because we try to avoid breaking code. So we
> > deprecate small parts of modules in every release which is a pita
> > for everyone. Dropping all sub-par code and fixing naming
> > conventions in one release would get us a clean restart without all
> > that cruft.
> 
> No, it won't, because names are a bikeshedding thing and every group
> of name changes spawns more name change proposals. Every big break
> (and we've done them before) spawns more big break proposals. We have
> to stop doing this, or D will never ever advance.

Did we really have big breaks before? If those didn't work out well
then another one is probably not a good idea.

Regarding names: Choosing the actual name often is bikeshedding but
naming conventions (casing, no underscores, etc) are well defined and
we still have modules in phobos which don't conform to them.
> 
> The existence of std.xml that is ignored and left out of the 
> documentation is not going to discourage people from using D, but 
> constantly telling people they have to rewrite their existing,
> working, and stable code will, as the start of this thread shows.
> 

But people may question the standard libraries quality if modules like
std.xml are part of it.


More information about the Digitalmars-d mailing list