-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Open
Description
The book mentions on p. 336 that the "private void printMenu (Iterator iterator)" method does not need to be changed. I'm running Eclipse IDE Version: 2022-03 (4.23.0) and the interpreter will complain with a warning that " Iterator is a raw type. References to generic type Iterator should be parameterized", as well as throw an error on the "MenuItem menuItem = iterator.next();" line, stating " Type mismatch: cannot convert from Object to MenuItem".
Changing "private void printMenu (Iterator iterator)" to "private void printMenu (Iterator iterator)" remove both the warning an error and solves the problem
Metadata
Metadata
Assignees
Labels
No labels