gnupic: Re: [gnupic] is OO any use?


Previous by date: 19 Aug 2005 15:56:16 +0100 Re: [gnupic] is OO any use?, David P Harris
Next by date: 19 Aug 2005 15:56:16 +0100 Re: [gnupic] is OO any use?, David McNab
Previous in thread: 19 Aug 2005 15:56:16 +0100 Re: [gnupic] is OO any use?, David P Harris
Next in thread: 19 Aug 2005 15:56:16 +0100 Re: [gnupic] is OO any use?, David McNab

Subject: Re: [gnupic] is OO any use?
From: ####@####.####
Date: 19 Aug 2005 15:56:16 +0100
Message-Id: <20050819104922.H39573@saddam.controlq.com>

On Fri, 19 Aug 2005, David McNab wrote:

> This fork is producing a forth that is very 'vanilla' and
> architecture-neutral, with the possibility af implementing the same
> language, API, runtime environment etc for other PICs, and even other
> ucontrollers such as the various AVR lines.

One of FORTH's forte's -- no?

>
> Also, this forth will be very usable as a backend for other language
> compilers, such as python (subset), C, Java subset.
>
> What I'm asking here is - is there any real practical value to be gained
> from supporting OOP in a PIC runtime environment?
>

While I can imagine a number -- my suggestion is implement it.  Those who
understand the issues will use it as the opportunity arises.

> I successfully implemented a reasonably efficient OO layer that supports
> most of the OO basics like inheritance, polymorphism and dynamic
> allocation (but no gc or refcounting), as well as early and late binding.

I'm not sure that garbage collection belongs on a PSOC for most
applications.  The indeterministic aspects of that would blow the timings
for any but the least demanding applications.  Late binding, on the other
hand offers flexibility in a turnkey system which should appeal to system
integrators ... and in spite of the costs (cpu cycles) offers runtime
driver selections, optional equipment support and a number of features
which might be useful.

> Your thoughts?
> Is OO on PIC a useless wank, or can it have real practical value?

The biggest impediment is the FORTH language itself.  Reverse polish, the
word concept and stack diagrams take a bit of a learning curve, however
once you are on to it, productivity is greatly enhanced.  I particularly
like the top down programming paradigm featured in Brodie's book Thinking
Forth ... as it lends itself naturally both to incremental hardware design
and software development.

Keep it up!
Cheers,
Rob.

Previous by date: 19 Aug 2005 15:56:16 +0100 Re: [gnupic] is OO any use?, David P Harris
Next by date: 19 Aug 2005 15:56:16 +0100 Re: [gnupic] is OO any use?, David McNab
Previous in thread: 19 Aug 2005 15:56:16 +0100 Re: [gnupic] is OO any use?, David P Harris
Next in thread: 19 Aug 2005 15:56:16 +0100 Re: [gnupic] is OO any use?, David McNab


Powered by ezmlm-browse 0.20.