Skip to content

Invalid VM instruction when setting routine as part of a tuple. #545

Description

@IngwiePhoenix
(dao) tup2 = ( cb = routine() {}, 'abc' )
[[ERROR]] in file "interactive codes":
  At line 0 : Invalid function definition --- " __main__() ";
  At line 1 : Invalid virtual machine instruction --- " SETVG:4,2,0 ";
In code snippet:
      4 :  TUPLE       :     2 ,     2 ,     4 ;     1;   ( cb = routine() {}, 'ab...'...
>>    5 :  SETVG       :     4 ,     2 ,     0 ;     1;   tup2
      6 :  RETURN      :     4 ,     1 ,     0 ;     1;   )
  At line 1 : Invalid operation on the type --- " tup2 ";
  At line 1 : Types not matching --- " 'tuple<cb:routine<=>none>,string>' for 'tuple<index:int,string>' ";

I just tried this out for fun. Well, this is what comes out.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions