Hi,

Is there a macro in Julia similar to CL's WITH-SLOTS? Eg

type Foo
  bar
  baz
end

function foo(f::Foo)
  @with_fields f (bar,baz)
    bar+baz
  end
end

would be the same as

function foo(f::Foo)
  f.bar + f.baz
end

If not, then some hints on how to write this would be welcome. I could
not find anything equivalent to symbol macros in Julia, which are used
to implement this in CL.

Best,

Tamas

Reply via email to