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

[Docs] [Builtins] Add Note [Constants vs built-in functions] #4563

Merged

Conversation

effectfully
Copy link
Contributor

Mostly extracted from an email.

@effectfully effectfully force-pushed the effectfully/docs/builtins/add-note-constants-vs-functions branch from 016a19e to c867b94 Compare April 27, 2022 17:39
@effectfully effectfully force-pushed the effectfully/docs/builtins/add-note-constants-vs-functions branch from c867b94 to 5c8f214 Compare April 27, 2022 23:50
@@ -139,6 +139,51 @@ nonZeroArg :: (Integer -> Integer -> Integer) -> Integer -> Integer -> Evaluatio
nonZeroArg _ _ 0 = EvaluationFailure
nonZeroArg f x y = EvaluationSuccess $ f x y

{- Note [Constants vs built-in functions]
A constant is anything of a built-in type. For example, 'Integer' is a built-in type, so anything of
type 'Integer' is a constant.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you mean "a constant is any value of built-in type"? (\x . x) (con 1) is of type integer but isn't a constant.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I meant "of a built-in type on the Haskell side". Gonna go with your wording, thanks.

@effectfully effectfully force-pushed the effectfully/docs/builtins/add-note-constants-vs-functions branch from 5c8f214 to 983e325 Compare April 28, 2022 13:11
@effectfully effectfully merged commit 99bd779 into master Apr 28, 2022
@effectfully effectfully deleted the effectfully/docs/builtins/add-note-constants-vs-functions branch April 28, 2022 13:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants