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

Visibility workaround for #1946 #1955

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 16 additions & 16 deletions libs/base/Language/Reflection.idr
Original file line number Diff line number Diff line change
Expand Up @@ -61,26 +61,26 @@ Monad Elab where
(>>=) = Bind

||| Report an error in elaboration
export
public export
fail : String -> Elab a
fail = Fail EmptyFC

export
public export
failAt : FC -> String -> Elab a
failAt = Fail

||| Write a log message, if the log level is >= the given level
export
public export
logMsg : String -> Nat -> String -> Elab ()
logMsg = LogMsg

||| Write a log message and a rendered term, if the log level is >= the given level
export
public export
logTerm : String -> Nat -> String -> TTImp -> Elab ()
logTerm = LogTerm

||| Log the current goal type, if the log level is >= the given level
export
public export
logGoal : String -> Nat -> String -> Elab ()
logGoal str n msg
= do g <- Goal
Expand All @@ -90,58 +90,58 @@ logGoal str n msg

||| Check that some TTImp syntax has the expected type
||| Returns the type checked value
export
public export
check : TTImp -> Elab expected
check = Check

||| Return TTImp syntax of a given value
export
public export
quote : (0 _ : val) -> Elab TTImp
quote = Quote

||| Build a lambda expression
export
public export
lambda : (0 x : Type) ->
{0 ty : x -> Type} ->
((val : x) -> Elab (ty val)) -> Elab ((val : x) -> (ty val))
lambda = Lambda

||| Get the goal type of the current elaboration
export
public export
goal : Elab (Maybe TTImp)
goal = Goal

||| Get the names of the local variables in scope
export
public export
localVars : Elab (List Name)
localVars = LocalVars

||| Generate a new unique name
export
public export
genSym : String -> Elab Name
genSym = GenSym

||| Given a name, return the name decorated with the current namespace
export
public export
inCurrentNS : Name -> Elab Name
inCurrentNS = InCurrentNS

||| Given a possibly ambiguous name, get all the matching names and their types
export
public export
getType : Name -> Elab (List (Name, TTImp))
getType = GetType

||| Get the type of a local variable
export
public export
getLocalType : Name -> Elab TTImp
getLocalType = GetLocalType

||| Get the constructors of a fully qualified data type name
export
public export
getCons : Name -> Elab (List Name)
getCons = GetCons

||| Make some top level declarations
export
public export
declare : List Decl -> Elab ()
declare = Declare
2 changes: 1 addition & 1 deletion src/Core/Normalise/Eval.idr
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ parameters (defs : Defs, topopts : EvalOpts)
pure def
evalRef env meta fc nt@Func n stk def
= do -- logC "eval.ref.func" 50 $ do n' <- toFullNames n
-- pure $ "Found function: " ++ show n'
-- pure $ "Fouand function: " ++ show n'
Just res <- lookupCtxtExact n (gamma defs)
| Nothing => pure def
let redok1 = evalAll topopts
Expand Down