Table with attribute
In Table
rule we have a variant to create a Table
object from a Tuple of parameters for the columns:
( 'Table' with_attr ?= 'with' 'columns' '=' columns_tuple = Tuple ) | ( '(' columns += Series[','] ')' )
Problems:
- 'with_attr' is used nowhere
- 'columns_tuple' is used only in typechecks.py::table_type() to fill columns list
The rule can be much more simple like this
'Table' 'with' 'columns' '=' ( '(' columns += TableColumnParameter[','] ')' )
TableColumnParameter:
Series | VarReference
;
Then we do not need 'with_attr' and 'columns_tuple' and the typechecker typechecks.py::table_type()
then does not do any copying. And all existing programs/tests will still work.