Live data from Hacker News

Ask HN: How should a programming language accommodate disabled programmers?

news.ycombinator.com

121–122 of 122 posts

Re: Ask HN: How should a programming language accommodate disabled programmers?

#121

Slightly off-topic: how do blind programmers read code? Does the screen reader recite it aloud and just say "int main left-paren void right-paren open-brace int i equals zero...", or does it use some other kind of auditory vocabulary to make it more meaningful to the listener? I've been thinking about this alot lately because I've been wondering how I could get better at programming while driving on my daily commute.

The most extreme sport: programming the car you're in to self-drive, without being able to touch the steering wheel, next to the grand canyon.

Re: Ask HN: How should a programming language accommodate disabled programmers?

#122
post #89

Earlier quoted context omitted.

Well it seems that OP needn’t bother as this problem is already solved. You wrote (loop (print (eval (read)))). How does that go with a screen reader? Like: Bracket loop bracket print bracket eval bracket read bracket bracket bracket bracket? The key thing I think is balancing and shifting parens. (loop (print (eval)) (read)) Is quite hard to sound different from (loop (print (eval (read)))) And more crucially what a…

”Bracket loop bracket print bracket…” A screen reader need not literally read what’s on screen. It typically doesn’t with prose, where punctuation isn’t spoken, but affects timing and intonation, and abbreviations often are expanded (iOS speaks “Dr. John St.” as “Doctor John Street”, for example, but “St. John Dr.” as “Saint John dee-ar”. MacinTalk used to know that ‘Dr’ means ‘Drive’) So, it need not do that here, a…

Requiring a sufficiently smart screen reader seems a bad way to go. 30 years on from CLtL we still don’t have a sufficiently smart compiler and I would argue that that problem is easier. One thing is that this works “better” with one-argument functions. Consider:

  (with-open-file (*standard-output* foo)
    (print x))
  (print y)
Vs

  (with-open-file (*standard-output* foo)
    (print x)
    (print y))
How do you read the first? As “print x, now with-the-file foo-open-as-standard-output it; then print y”? Or maybe “with foo opened as standard output, print x; now print y”?

This seems more reasonable but how do you write the second example? Like “with foo opened as standard output, print x; also print y”?

There are reasonably large semantic differences in such cases and many programming languages, including lisp, express them with subtle hard-to-pronounce differences in indentation or parenthising of expressions.

Post reply on HN