I found the following example here
instance Monad Maybe where
Nothing >>= f = Nothing
(Just x) >>= f = f x
return = Just
The return method is defined in the pointfree style, which I know is applicable to functions, but here we have a data constructor whose declaration syntax looks different from the one of functions let alone its purpose.
Another tutorial says:
Data constructors are first class values in Haskell and actually have a type. For instance, the type of the Left constructor of the Either data type is:
Left :: forall b a. a -> Either a b
As first class values, they may be passed to functions, held in a list, be data elements of other algebraic data types and so forth.
So can anyone make it clear what data constructors are and how they are different from functions if anything.