[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: LFM + LFSP = LFE?



At 10:16 AM -0700 6/12/03, Avi Bryant wrote:
>On Thu, 12 Jun 2003, Scott McKay wrote:
>
>>    - Many organizations rely on some sort of source
>>      version control systems, and I have yet to see
>>      commercial-grade systems that use something
>>      other than flat files.
>>    - Who says that "files" are not allowed to obey
>>      protocols that allow them to be accessed along
>>      axes other than a "stream of bytes"?  The editor
>>      I wrote for Harlqn/FunO Dylan treated source
>>      files as databases, even though they happened
>>      to be stored in flat files that could be checked
>  >     in to/out of traditional source control systems.
>
>
>To give you an example, if I wanted to count the total number of lines of
>code in a particular class hierarchy, I would execute
>
>FooClass withAllSubclasses detectSum: [:c | c linesOfCode].
>

This functionality has absolutely nothing to do with
whether or not source code is stored in files, which
was the point of my second bullet item.  The protocols
being used here are:
  - Given a class, generate its subclasses
  - Given a class, go find its source code
  - Given a piece of source count, count the lines in it
This was all supported in the Harlqn Dylan environment,
with no mucking around with importing and exporting. (*)

----------
(*) It was not a goal for the Dylan environment to be
programmable, so a user could not do this programmatically.
You could do it by going into Deuce (its editor), editing
all the subclasses of <Foo>, and then executing a count
lines command in the "composite" buffer created by the
"edit subclasses" command.  Of course, you could also
edit the composite buffer and save the changes, which
would write everything back into its proper home.  Even
though I wrote this editor, I found it a bit unnerving
to be able to do sweeping changes like this, which would
simultaneously change possibly dozens of source files.