Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin
Znav
nextRuby Mapping for Exceptions
prevRuby Mapping for Dictionaries

Here are the constant definitions once more:

Wiki Markup
{zcode:slice}
const bool      AppendByDefault = true;
const byte      LowerNibble = 0x0f;
const string    Advice = "Don't Panic!";
const short     TheAnswer = 42;
const double    PI = 3.1416;

enum Fruit { Apple, Pear, Orange };
const Fruit     FavoriteFruit = Pear;
{zcode}

The generated definitions for these constants are shown below:

Wiki Markup
{zcode:rb}
AppendByDefault = true
LowerNibble = 15
Advice = "Don't Panic!"
TheAnswer = 42
PI = 3.1416
FavoriteFruit = Fruit::Pear
{zcode}

As you can see, each Slice constant is mapped to a Ruby constant with the same name.

Ztop
See Also
Zret
Znav
nextRuby Mapping for Exceptions
prevRuby Mapping for Dictionaries