0
\$\begingroup\$

Without using any of the standard Inform libraries, what is the minimal amount of code / infrastructure needed to support the <action> syntax?

What I tried is

Verb 'foo' * -> Foo;

[ FooSub;
    "Hello from FooSub";
];

[ Main;
  <foo>;
];

I expected this to print Hello from FooSub when run; however, the output I get is

Action <0 0 0>
\$\endgroup\$

1 Answer 1

0
\$\begingroup\$

By bisecting the standard parserm.h file, I've found that the secret sauce is the platform function R_Process. By adding the following implementation of it to my code:

[ R_Process a;
    indirect(#actions_table-->a);
];

I got <foo> to work.

\$\endgroup\$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .