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

Distribution definition in BLOG. #148

Open
lileicc opened this issue Jun 4, 2014 · 1 comment
Open

Distribution definition in BLOG. #148

lileicc opened this issue Jun 4, 2014 · 1 comment

Comments

@lileicc
Copy link
Contributor

lileicc commented Jun 4, 2014

In BLOG, we define some library module with the following statement

distribution Real Gaussian(Real mu, Real std) = Gaussian(mu, std);

It defines a Gaussian distribution, with two Real parameters, and a Real return value. Its implementation is the Gaussian class (which is blog.distrib.Gaussian).
Equivalently, we could also state

distribution Real Gaussian(Real mu, Real std) = blog.distrib.Gaussian(mu, std);

Related to #136 .

@lileicc lileicc closed this as completed Jun 7, 2014
@lileicc lileicc reopened this Jun 7, 2014
@lileicc lileicc changed the title Native interface definition for distribution. Distribution definition in BLOG. Jun 7, 2014
@cberzan
Copy link
Contributor

cberzan commented Jun 10, 2014

👍 This would allow type-checking on distributions, and avoid bugs like #155 that currently lead to confusing error messages.

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

2 participants