News for hackers. Stuff that matters.
Re:Ask HN: How should a programming language accommodate dis... by gus_massa on Friday November 09, 2018 @09:54AM (#18414758)
> Making whitespace-sensitive syntax, like in Python & Haskell, optional syntactic sugar for explicit brackets & separators.

Interesting question. A few years ago, I worked with a blind mathematician. I was an undergraduate T.A. and he was the main T.A. of the course. He used the screen reader a lot. In particular, he has the list of exercise in LaTeX. We read aloud the grades of the students and he wrote them in the Excel form.

I don't remember him using a programming language (excluding LaTeX). The indentation looks like a difficult problem, even if the language has explicit brackets. Does the screen reader say "Tab Tab print ten semicolon"? Does it ignore the indentation? Spaces vs tabs? ...

Do you have some group of blind programmers that you can ask about their current setup?

Re:Ask HN: How should a programming language accommodate dis... by TheCoreh on Friday November 09, 2018 @10:08AM (#18414895)
Not knowledgable about screen readers, but maybe having the increase in indentation result in an increase in pitch of the screen reader voice could be an interesting approach for this.
Re:Ask HN: How should a programming language accommodate dis... by pavel_lishin on Friday November 09, 2018 @10:16AM (#18414971)
You beat me to this idea by five minutes!

Another bonus to this approach is that it enforces a style guide. Overly complicated and nested programs become more difficult to understand, and excessive nesting becomes literally incomprehensible as it spirals out of the human hearing range.

I wonder if you could also use different voices for different things. Code could be read in a masculine tone, code blocks in a feminine tone, inline strings with an Australian accent.

Re:Ask HN: How should a programming language accommodate dis... by abalos on Friday November 09, 2018 @10:01AM (#18414823)
I wonder if it would be helpful to describe the indentation level you are on:

e.g:

  def method_here(value): # Indentation level 0
    x = 10 # Level 1
    y = 5  # Level 1
    if x == value # Level 1
      print 'x!' # Level 2
    elif y == value # Level 1
      print 'y!' # Level 2
You could maybe even throw in a block number so it's clearer.
Re:Ask HN: How should a programming language accommodate dis... by ctoth on Friday November 09, 2018 @11:35AM (#18415647)
Check out how this actually works:

https://github.com/derekriemer/nvda-indentone

Re:Ask HN: How should a programming language accommodate dis... by abalos on Friday November 09, 2018 @03:17PM (#18417572)
That's awesome, thanks for sharing that!