comp.lang.ada
 help / color / mirror / Atom feed
From: Maxim Reznik <reznikmm@gmail.com>
Subject: Re: Advent of code day 12
Date: Sun, 13 Dec 2020 10:35:58 -0800 (PST)	[thread overview]
Message-ID: <cedd7bfc-18d9-4718-8ac2-1324656551cen@googlegroups.com> (raw)
In-Reply-To: <5dd52f99-49c3-4403-859b-58f8bfdabfb7n@googlegroups.com>

Take a look at Ada 2005 Rationale:
https://www.adaic.org/resources/add_content/standards/05rat/html/Rat-2-7.html

The `overriding` specification is optional only to keep backward compatibility with Ada 83/95. Usage of this keyword prevents you from errors, when you expect some function to override another from the parent type, but occasionally it doesn't. For instance, if one day you rename 'Turn' on interface type to, say, `Rotate`, without `overriding` keyword the program still compiles, but won't work as expected. So `overriding` must be :)


воскресенье, 13 декабря 2020 г. в 17:41:27 UTC+2, john....:
> On Sunday, December 13, 2020 at 12:40:35 AM UTC-6, Maxim Reznik wrote: 
> > I used interface and tagged types to make solution more interesting :) 
> > 
> > https://github.com/reznikmm/ada-howto/blob/advent-2020/md/12/12.md
> Yes, I look at all the solutions listed on your Advent of Code page at GitHub because I appreciate interesting answers, thank you. :-) 
> 
> This reminds me, though; you declare the Controls package, but in both Part_1 and Part_2 you use "overriding" only on the Move procedure, not on any other. I'm not familiar with interfaces yet; is there a reason you used that word there and nowhere else?

  reply	other threads:[~2020-12-13 18:35 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-12 20:28 Advent of code day 12 Stephen Leake
2020-12-13  1:33 ` John Perry
2020-12-13  6:40   ` Maxim Reznik
2020-12-13 11:36     ` Gautier Write-Only Address
2020-12-13 15:41     ` John Perry
2020-12-13 18:35       ` Maxim Reznik [this message]
2020-12-13 22:29         ` John Perry
2020-12-14  9:15           ` Maxim Reznik
2020-12-14  0:01         ` Stephen Leake
2020-12-13  9:14   ` Gautier Write-Only Address
2020-12-13 15:32     ` John Perry
2020-12-13  9:30   ` Jeffrey R. Carter
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox