At 04:52 PM 4/18/2005, chromatic wrote:
On Mon, 2005-04-18 at 14:44 +0200, Leopold Toetsch wrote:
> Yep. As a first step, I'd redefine this to be C<.label>:
>
>.macro SpinForever (Count)
> .label $LOOP: dec .COUNT# ".label $LOOP" defines a local label.
>branch .$LOO
On Mon, 2005-04-18 at 14:44 +0200, Leopold Toetsch wrote:
> Yep. As a first step, I'd redefine this to be C<.label>:
>
>.macro SpinForever (Count)
> .label $LOOP: dec .COUNT# ".label $LOOP" defines a local label.
>branch .$LOOP # Jump to said label.
>.endm
Ca
William Coleda <[EMAIL PROTECTED]> wrote:
> Macros support labels, defined using B<.local>, that are local to a
> given macro expansion. The syntax looks something like this:
> .macro SpinForever (Count)
> .local $LOOP: dec .COUNT# ".local $LOOP" defines a local label.
>
Matt Diephouse wrote:
William Coleda <[EMAIL PROTECTED]> wrote:
6) avoid using ".local" to mean something different based on context (macro or not)
I'm not sure what you mean.
.local inside a macro is actually a label, not a variable. From the imcc
docs:
---
Macros support labels, defined using
William Coleda <[EMAIL PROTECTED]> wrote:
> But... this isn't actually enforced. You can do:
>
> .local String foo
> foo = new Blorp
>
> Basically, anything that isn't one of the basic types is interpreted as "pmc".
I think this is misleading.
> 1) make
>
> .local String foo
>
> (and .sym) eq
Currently, the following syntax is allowed, and used in examples and code
throughout the repository:
.local String foo
foo = new String
.sym String bar
bar = new String
But... this isn't actually enforced. You can do:
.local String foo
foo = new Blorp
Basically, anything that isn't one of the ba