Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

numeric expression should not evaluate to const type #19611

Open
dlangBugzillaToGithub opened this issue Aug 22, 2019 · 1 comment
Open

numeric expression should not evaluate to const type #19611

dlangBugzillaToGithub opened this issue Aug 22, 2019 · 1 comment

Comments

@dlangBugzillaToGithub
Copy link

Илья Ярошенко reported this on 2019-08-22T14:29:44Z

Transferred from https://issues.dlang.org/show_bug.cgi?id=20152

CC List

  • ag0aep6g

Description

void main()
{	
	const double a = 1, b = 2;
	pragma(msg, typeof(a * b));
}

prints `const(double)`

expected result: `double`
@dlangBugzillaToGithub
Copy link
Author

ag0aep6g commented on 2019-08-22T14:40:39Z

This is not a regression. Downgrading to "normal". Ultimately, this is probably an enhancement request, unless the spec states that the type should be `double`.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant