Skip to content

Comment on Experiments with Nimrodparent

Comments

What I'd actually be doing is more like:

  when ROBOT_VER == 32:
    type TSonarAddresses = array[0..3, int]
    const sonarAddresses: TSonarAddresses = [1,2,3,4]
    ...
  elif ROBOT_VER == 33:
    ...
and stuff like that.

I see. Good, that is precisely what 'when' should be used for :)

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.