| Summary: | Compile errors assigning numeric array literals to array fields | ||
|---|---|---|---|
| Product: | z_Archived | Reporter: | Justin Spadea <jspadea> |
| Component: | EDT | Assignee: | Project Inbox <edt.javagen-inbox> |
| Status: | CLOSED FIXED | QA Contact: | |
| Severity: | normal | ||
| Priority: | P3 | CC: | jeffdouglas, lasher, mheitz |
| Version: | unspecified | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Linux | ||
| Whiteboard: | |||
|
Description
Justin Spadea
fixed I'm still seeing compile errors on three of them (3rd, 5th, and 6th). Yes, and according to Matt, this is a user error. Matt says that if the user is trying to assign non-ints to an integer array, that is a user problem. Perhaps validation would be able to help. If you want me to revisit this, that would be okay, but as I recall we don't know the type of the array when the literals are being processed Jeff, I'm reopening this because I'd like you to discuss it with Tim. Decide what should happen: a validation error or a runtime error. We shouldn't be generating code that doesn't compile for this. Also, if we don't already have one, please open a bug for the problem where the type of an array literal is wrong. Given the latest round of language changes and commandments from Tim, most of the assignment statements in this defect are invalid. An array literal can only be assigned to a variable of exactly the same type. I opened bug 357833 so the compiler will start rejecting the invalid stuff. Changing this from invalid to fixed since it does indeed work now. |