June 20, 2008
Jarrett Billingsley wrote:
> Crap, tried compiling something and got this:
> 
> Assertion failure: 'global.errors' on line 272 in file 'statement.c'

Sorry 'bout that. Fix will go out in next update.
June 20, 2008
Jarrett Billingsley wrote:
> 617 doesn't seem to work.  The example in bugzilla doesn't, anyway. 

The example works if size_t is replaced with uint. Arggh. I'll do a better fix next update.
June 20, 2008
Jarrett Billingsley wrote:
> "Georg Wrede" <georg@nospam.org> wrote in message news:485AFE87.3050902@nospam.org...
> 
>>Do the Tango guys have such a backend??
> 
> No, they just have permission to redistribute the DMD binary.  Walter is the only one who has access to the backend. 

I wasn't talking about back end sources.
June 20, 2008
Georg Wrede wrote:

> Jarrett Billingsley wrote:
>> "Walter Bright" <newshound1@digitalmars.com> wrote in message news:g3bqmi$2117$1@digitalmars.com...
>>>Jarrett Billingsley wrote:
>>>>And if something like this _is_ too much work for one man -- why not put the DMDFE source on dsource and start accepting help on things like this?
>>>
>>>Reorganizing the internals of the compiler is not just accepting a patch.
>>>
>>>I've incorporated many user patches to dmd. The source doesn't need to be on dsource for that.
>> 
>> I'm not suggesting patches.  I'm suggesting that you not be the *only*
>> person working on DMDFE.  I'm also suggesting that if the internals need
>> to
>> be reorganized to implement forward reference resolution -- so be it.
>> Maybe
>> the compiler needs to be rewritten.  It's been in development an awfully
>> long time and D has changed considerably since development started.  The
>> semantic analysis that used to cut it when it wasn't much more complex
>> than Java might not be working for us anymore.
> 
> We've had this discussion in the past, and Walter has said it's OK for anybody to make changes to the FE, that's why it's open source.
> 
> That means that you /already/ can put it on dsource and have people send you patches. You can then automatically (say once a day or week) have the thing compiled, regression test suite run, and have the binary put on download.

The frontend is already on dsource (dmdfe), and is used by various projects
(rebuild, etc).

-- 
Lars Ivar Igesund
blog at http://larsivi.net
DSource, #d.tango & #D: larsivi
Dancing the Tango
June 20, 2008
Georg Wrede wrote:

> Jarrett Billingsley wrote:
>> "Walter Bright" <newshound1@digitalmars.com> wrote in message news:g3bqmi$2117$1@digitalmars.com...
>>>Jarrett Billingsley wrote:
>>>>And if something like this _is_ too much work for one man -- why not put the DMDFE source on dsource and start accepting help on things like this?
>>>
>>>Reorganizing the internals of the compiler is not just accepting a patch.
>>>
>>>I've incorporated many user patches to dmd. The source doesn't need to be on dsource for that.
>> 
>> I'm not suggesting patches.  I'm suggesting that you not be the *only*
>> person working on DMDFE.  I'm also suggesting that if the internals need
>> to
>> be reorganized to implement forward reference resolution -- so be it.
>> Maybe
>> the compiler needs to be rewritten.  It's been in development an awfully
>> long time and D has changed considerably since development started.  The
>> semantic analysis that used to cut it when it wasn't much more complex
>> than Java might not be working for us anymore.
> 
> We've had this discussion in the past, and Walter has said it's OK for anybody to make changes to the FE, that's why it's open source.
> 
> That means that you /already/ can put it on dsource and have people send you patches. You can then automatically (say once a day or week) have the thing compiled, regression test suite run, and have the binary put on download.
> 
> Once a particular patch has been used by enough people, it becomes easier to suggest Walter incorporate it in Phobos.

FE is not the same as Phobos (or runtime), although there clearly are parts of the FE requiring things to be in the runtime. The runtime parts required by the FE isn't very exciting though, and probably not where it is easy to find much to patch. The only time Phobos would be relevant in this context, would be if a new patch to the FE _also_ required a change/addition on the runtime.

-- 
Lars Ivar Igesund
blog at http://larsivi.net
DSource, #d.tango & #D: larsivi
Dancing the Tango
June 20, 2008
Walter Bright wrote:
> Sascha Katzner wrote:
>> I would love this too. A bootstrapped compiler is like the ultimate statement from a developer that he thinks his product is mature enough that even he himself uses it. I think when D has achieved this goal, it is finally adult. :)
> 
> The problem with a D compiler in D is that nearly every compiler back end is in C or C++, and having the D front end in C++ makes it easier to connect to existing back ends.

For people interested in this, I also host a binding+wrapper of the LLVM C interface  in the LLVMDC svn repository :)

http://dsource.org/projects/llvmdc/browser/binding/llvm

> 
> Many, many times, however, I wished it was in D just because it would make coding it easier.
June 20, 2008
"Georg Wrede" <georg@nospam.org> wrote in message news:485B64BC.9010707@nospam.org...
> Jarrett Billingsley wrote:
>> "Georg Wrede" <georg@nospam.org> wrote in message news:485AFE87.3050902@nospam.org...
>>
>>>Do the Tango guys have such a backend??
>>
>> No, they just have permission to redistribute the DMD binary.  Walter is the only one who has access to the backend.
>
> I wasn't talking about back end sources.

Well that's the only form it exists in ;)


June 20, 2008
Robert Fraser wrote:
> How pluggable is LLVMDC? For example, if it uses the visitor pattern &
> just public interfaces,it might be possible to replace the DMD classes with wrappers around classes generated from another front-end (maybe even a D one with a C go-between... sounds complex, but I might be willing to do that part).

LLVMDC is unfortunately not pluggable at all. Also DMDFE has some pretty weird AST constructs, and the codegen code is very much tied to the specific ASTs (and the info they hold) that DMDFE produces.
June 20, 2008
On Fri, 20 Jun 2008 16:00:39 +0400, Jarrett Billingsley <kb3ctd2@yahoo.com> wrote:

> "Georg Wrede" <georg@nospam.org> wrote in message
> news:485B64BC.9010707@nospam.org...
>> Jarrett Billingsley wrote:
>>> "Georg Wrede" <georg@nospam.org> wrote in message
>>> news:485AFE87.3050902@nospam.org...
>>>
>>>> Do the Tango guys have such a backend??
>>>
>>> No, they just have permission to redistribute the DMD binary.  Walter is
>>> the only one who has access to the backend.
>>
>> I wasn't talking about back end sources.
>
> Well that's the only form it exists in ;)
>
>

What about putting *compiled* (not the sources) backend (as a lib) to a public as well, so that people could build a DMD themselves? This would be a *huge* step forward. People would be able make some play with it, fix some bug, run tests and propose the patch to Walter.

Does putting backend in a compiled form to digitalmars.com/dsource involve any copyright infringements?
June 20, 2008
Walter Bright, el 19 de junio a las 14:52 me escribiste:
> Leandro Lucarella wrote:
> >Walter Bright, el 19 de junio a las 12:08 me escribiste:
> >>Many, many times, however, I wished it was in D just because it would make coding it easier.
> >I don't think I have to tell *you* this, but since D is link compatible with C, I don't think that's a real issue...
> 
> It is, for a couple reasons:
> 
> o  Some back ends (like mine) is in C++, not C.

But you can access C from C++!

> o  If you're porting D to a platform that has no existing D compiler on it, you're in for some significant problems.

Yes, that's true, but that can be solved making a D compiler that can emits C code instead of asm/binary (just to boostrap in new platforms that have a C compiler). I think LVMM can do that, right?

-- 
Leandro Lucarella (luca) | Blog colectivo: http://www.mazziblog.com.ar/blog/
----------------------------------------------------------------------------
GPG Key: 5F5A8D05 (F8CD F9A7 BF00 5431 4145  104C 949E BFB6 5F5A 8D05)
----------------------------------------------------------------------------
Y tuve amores, que fue uno sólo
El que me dejó de a pie y me enseñó todo...