Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ada: Fix crash during function return analysis
The compiler would crash when checking type relation between the function's return type and the type of the expression used in the return statement. It would not work if the function's return type is an access type and the expression is not. gcc/ada/ * sem_ch6.adb (Analyze_Function_Return): Add missing Is_Access_Type check before accessing the Designated_Type field. Tested on x86_64-pc-linux-gnu, committed on master.
- Loading branch information