auctionInstance = Scripts.validator @Auctioning
hello = logInfo @String "Hello, world"
Cardano Stack Exchange is a question and answer site for users and developers of the Cardano cryptocurrency ecosystem. It only takes a minute to sign up.Sign up to join this community
It means type application.
In this case, the function is polymorphic with the following type:
logInfo :: forall a effs. Member (LogMsg a) effs => a -> Eff effs ()
by using TypeApplications extension, you can use
@SomeType hint for the compiler, so the
logInfo call is not ambiguous.
logInfo @String "Hello world" means apply type
String to functions type variable
a (the order depends on the order of type variables in explicit
forall section -
forall a effs - sometimes you may want to add multiple hints e.g.
convert @String @Text someArg otherArg).
Ambiguity here stems from multiple string types in Haskell so you need to tell the compiler which type you are using (