next version of DWT?

Marcin Kuszczak aarti at
Sun Apr 29 06:36:33 PDT 2007

Frank Benoit wrote:

> Now again we have to change the method name to make it unique :)
> I would prefer to let the original have the original name, and have the
> helper method have the changed name.
> And if it is needed for the return type, i would do it for all helpers.
> 'swt' is not working as a general 'escaping sequence' (porting other
> projects)
> How about 'dh_' ? :)

I just have strong feeling that having good D-ish API for any ported from
Java project is crucial to its wide adoption. So any solution which would
allow this will be good.

If methods with 'dh_' prefix will not be intended for use by library users,
I don't care much about it. This prefix can stay, but API for users should
be clean. (Maybe even this prefix should be longer to make sure that no
collision will occur?)

Because of problems with templates I have another proposition. It is
consistent and should work good.

For every method taking character arrays, define 3 methods with suffixes to
their names:

void set(char[] a, char[] b, char[] c); // empty suffix
void setW(wchar[] a, wchar[] b, wchar[] c); // suffix "W"
void setD(dchar[] a, dchar[] b, dchar[] c); // suffix "D"

Same can be done for methods which returns different return types:

char[] getText();
wchar[] getTextW();
dchar[] getTextD();

Please just do not make 'dh_' methods standard way of using SWT port by D

I will not be able to answer your posts from now till Thursday evening
because I am leaving for vacation. But I hope that I was a little bit
helpful with my suggestions... I really appreciate your work on TioPort and
SWT. Good luck!

Marcin Kuszczak (Aarti_pl)
Ask me why I believe in Jesus - (en/pl)
Doost (port of few Boost libraries) -

More information about the Digitalmars-d-dwt mailing list