def preplace(schema, reverse_lookup, t):
    """
    Replaces basic types and enums with default values.

    :param schema:
        the output of a simplified schema

    :param reverse_lookup:
        a support hash that goes from typename to graphql type, useful to navigate the schema in O(1)

    :param t:
        type that you need to generate the AST for, since it is recursive it may be anything inside the graph

    """
    if t == 'String':
        return '@code@'
    elif t == 'Int':
        return 1334
    elif t == 'Boolean':
        return 'true'
    elif t == 'Float':
        return 0.1334
    elif t == 'ID':
        return 14
    elif reverse_lookup[t] == 'enum':
        return list(schema['enum'][t].keys())[0]
    elif reverse_lookup[t] == 'scalar':
        # scalar may be any type, so the AST can be anything as well
        # since the logic is custom implemented I have no generic way of replacing them
        # for this reason we return it back as they are
        return t
    else:
        return t