Unit conversion issue

I’m getting an error that I don’t understand, obtained by directly copying the example in WWI 15.11 Named notations:

"Unit Conversion Issue"

A weight is a kind of value. 10kg specifies a weight. 
1 tonne (singular) specifies a weight scaled up by 1000. 
2 tonnes (plural) specifies a weight scaled up by 1000.

The maximum load is initially 400kg.

When play begins:
	say "The weighbridge warns you not to exceed [maximum load in tonnes]."

A Problem message is issued:

Problem. You wrote ‘say “The weighbridge warns you not to exceed [maximum load in tonnes].”’, but ‘maximum load’ has the wrong kind of value: a weight rather than a table column.

I’m seeing this in both 6M62 and 10.1. Any ideas?

The say example line uses these lines:

1 tonne (singular, in tonnes) specifies a weight scaled up by 1000. 
2 tonnes (plural, in tonnes) specifies a weight scaled up by 1000.

Ah, I get it. The (in tonnes) notation makes a sayable value with structure [W - weight] in tonnes that will be expressed in the specified unit.

So the “table column” part of the Problem message is just the compiler trying to figure out what “in tonnes” might mean in the absence of that sayable value?

For the record, the docs seem pretty unclear here, especially because of the following text (bolding mine):

Although Inform’s habit of choosing the best notation available is usually just what we want, we sometimes want to make the choice ourselves. For instance, if we were printing out a table of different weights, we might want to give all of them in kilograms, whatever their size. In that case we can, if we want, give names to our different notations…

… and then goes on to set up saying weights in tonnes – doubly confusing because the default unit of weight is already kg.

A more comprehensive and clearer example might be:

A weight is a kind of value. 10g specifies a weight.
1kg (in kg) specifies a weight scaled up by 1000.
1 tonne (singular, in tonnes) specifies a weight scaled up by 1000000.
2 tonnes (plural, in tonnes) specifies a weight scaled up by 1000000.

The maximum load is initially 400kg.

When play begins:
	say "The weighbridge warns you not to exceed [maximum load in tonnes] (which is [maximum load in kg] in the metric system)."
1 Like