summaryrefslogtreecommitdiff
path: root/src/lj_ctype.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lj_ctype.c')
-rw-r--r--src/lj_ctype.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/lj_ctype.c b/src/lj_ctype.c
index 68edb287..7ef00521 100644
--- a/src/lj_ctype.c
+++ b/src/lj_ctype.c
@@ -328,6 +328,14 @@ CTInfo lj_ctype_info(CTState *cts, CTypeID id, CTSize *szp)
return qual;
}
+/* Ditto, but follow a reference. */
+CTInfo lj_ctype_info_raw(CTState *cts, CTypeID id, CTSize *szp)
+{
+ CType *ct = ctype_get(cts, id);
+ if (ctype_isref(ct->info)) id = ctype_cid(ct->info);
+ return lj_ctype_info(cts, id, szp);
+}
+
/* Get ctype metamethod. */
cTValue *lj_ctype_meta(CTState *cts, CTypeID id, MMS mm)
{