Hi there,

for both convenience and considerably improved source readability and 
robustness, I am considering an ASTT which would convert positional arguments 
to named ones, i.e., something like

@Named foo(bar,int bax=666,List baz) {
  ... whatever ...
}

turned to something like

foo(Map __map=null) {
  def bar=__map?.bar
  int bax=__map?.bax==null?666:__map?.bax
  List baz=__map?.baz
  ... whatever ...
}

In farther future with my own typechecking script it might even allow to 
typecheck named arguments, though that might prove a bit at the difficult side 
— but technically possible.

Has anybody tried something like that before? If so, bumped into some hidden 
pitfalls perhaps?

Thanks,
OC

Reply via email to