@@ -227,6 +227,10 @@ elabCon info syn tn codata expkind (doc, argDocs, n, t_in, fc, forcenames)
227227 logLvl 5 $ "Inaccessible args: " ++ show inacc
228228 logLvl 2 $ "---> " ++ show n ++ " : " ++ show cty'
229229
230+ -- Add to the context (this is temporary, so that later constructors
231+ -- can be indexed by it)
232+ updateContext (addTyDecl n (DCon 0 0 False) cty)
233+
230234 addIBC (IBCDef n)
231235 checkDocs fc argDocs t
232236 doc' <- elabDocTerms info doc