Thanks for clarifying the problem with IEEE library code. I was in fact assuming that the variable declaration in your code causes the warning.
The problem is sligthly different and hasn't to do with constant versus variable. It's quite normal, that variables inside library functions are involved when calculating constants. The warning is due to the fact, that the initial value expression in variable declaration isn't understood by Quartus as an actual assignment. You may consider this as a minor Quartus bug.
P.S.: The message directive
-- altera meassage_off xxxxx isn't supported for packages, so the issue has to be resolved by Altera.