Opened 4 years ago

Closed 4 years ago

#638 closed defect (fixed)

Error in index type inference.

Reported by: robertwb Owned by: robertwb
Priority: major Milestone: 0.14.1
Component: Type Analysis Keywords:
Cc:

Description

 def bar(foo):
     qux = foo
     quux = foo[qux.baz]

The error message:

       $ cython bar.py

       Error compiling Cython file:
       ------------------------------------------------------------
       ...
       def bar(foo):
               qux = foo
               quux = foo[qux.baz]
                     ^
       ------------------------------------------------------------

       /Users/daniel/Desktop/cython-test/bar.py:3:15: Object of type '<unspecified>' has no attribute 'baz'

Change History (2)

comment:1 Changed 4 years ago by robertwb

  • Owner changed from somebody to robertwb

The problem was that the indexing operator inference was changed to depend on the index type, but its type_dependencies method wasn't updated to reflect this.

comment:2 Changed 4 years ago by robertwb

  • Resolution set to fixed
  • Status changed from new to closed
Note: See TracTickets for help on using tickets.