I\'m beginning Haskell... I tried to write the following trivial function in two different ways, letting Haskell decide the types, and the type system does something different i
Because the definition of g doesn't explicitly name its arguments, you run into the monomorphism restriction, preventing g from being polymorphic and (in this case) causing GHC to default to Integer.