Jon,
>> My other conclusion was that what developers considered to
>> be 'natural' were those constructs they had lots of experience with.
>> I would claim that your preferences are derived from what you have
>> learnt from reading Haskell (and other languages) source code.
>
>Quite possibly, but that's hardly material. We are
>concerned with what kind of misreading someone who is used
>to the language will tend to make.
Are you planning to make changes to the syntax?
> Besides, some of the
>prior experience is of reading ordinary text, where bulleted
>or numbered lists typically use indentation to indicate
>nesting. What we want is for the effects of the cues to
>match the expectations.
The example you give of readers matching lines along an
edge is the likely looking automatic response for them to make.
Other than telling developers to use explicit bracketing, what
more can you do? Are you planning a Lint like tool for Haskell?
>do thing1
> thing2-p1
> <op> thing2-p2
>
>comes out as do {thing1; thing2-p1} <op> thing2-p2
>
>and I think that's really bad, because "from a visual
>perspective '<op> thing2-p2' is perceived as being at the
>same 'level' as thing1 and thing2-p1"
>> >It's this quoted statement for which I need some sort of
>> >theoretical support.
>>
>> I think you are simply a creature of your past experiences.
>
>I think we all are. But the experiences of Haskell
>programmers will be of Haskell programmes.
A good starting point would be to look at existing Haskell
programs. What are the commonly seen indentation conventions
that developers use, when is explicit bracketing used and when not,
etc.
I am carrying out the same exercise for C and have had a few surprises.
If developers are creatures of past experience, then that experience
is embedded in existing source. It would be useful to know what it is.
> I don't know
>anything like enough about the psychology to express what I
>mean, but it seems to me that the learning of layout rules
>can modulate but not completely override lower-level issues,
>so in designing the layout rule we have a certain amount of
>freedom, but if we push it too far, then misreadings will be
>more frequent even in experienced programmers.
Even with my limited reading of the literature it is plain that
the extent to which autonomous processes interact with
conscious cognitive processes is a hotly debated issue.
In some cases researchers don't even seem to have reached any
consensus on the stages in which input stimuli are processed.
My approach to coding guidelines has been to try and recommend
practices that insure all stages of processing are working together.
Depending on lower level processes being overridden by later processes
>> The paper by Quinlan discussed in sentence 763 (see figure 6) found
>> a 50/50 split of the population, in how items were grouped.
>
>Figure six doesn't look to me like the case under
>consideration.
I mentioned it as a case where there is no general agreement, across the
population, about how items are to be grouped. If there is no general
agreement at such a low level, what hope is there of predicting behavior
at higher levels?
> From my limited grasp of the terminology, I'm
>very surprised if the corners formed by the changes in left
>margin in
>
>adslfja asfa a as
>asdfkaf asdffsad
> asdflkjsdfa asf
> asdfkasdf afsddfsaf
> asdflkjdfa asf
> asfdlka
> asdfkljfsa
> asdffsad afsfassf
> asfdfdasfd
>safdsadf
>
>are not located by pre-cognitive processing. Is that really
>the case?
You might like to look at Chapter 7 of "Vision Science" by
Stephen Palmer. This discusses the 'parsing' process (see
figure 7 of sentence 763), where discontinuities are analysed.
I have not looked at this in detail and cannot offer any suggestions.
>If it is, then we still have it that haskell programmers
>will learn that basic property of the layout rule, and my
>suspicion is that the current exceptions to the rule to
>allow same-line closing of nestings are a bad choice.
I think that relying on indentation only, to signal syntax, is
a bad idea. As luck would have it I was talking in the pub tonight
with some Python programmers. They thought that using indentation
for this purpose was a great idea. I completely failed to convince
them of the inherent dangers (my complete lack of knowledge about
Python did not help). They were so engrossed in writing 'neat' code
that they had no thoughts for subsequent readers of their code. I
frequently encounter this outlook, so I should not be surprised by it.
But this time I thought I was onto a winner.
derek
--
Derek M Jones tel: +44 (0) 1252 520 667
Knowledge Software Ltd mailto:[EMAIL PROTECTED]
Applications Standards Conformance Testing http://www.knosof.co.uk
- Automatic footer for [EMAIL PROTECTED] ----------------------------------
To unsubscribe from this list, mail [EMAIL PROTECTED] unsubscribe discuss
To join the announcements list, mail [EMAIL PROTECTED] subscribe announce
To receive a help file, mail [EMAIL PROTECTED] help
This list is archived at http://www.mail-archive.com/discuss%40ppig.org/
If you have any problems or questions, please mail [EMAIL PROTECTED]